@@ -54,17 +54,14 @@ const opencode = await createOpencode({
5454const sessionCache = new Map < string , string > ( ) ;
5555
5656export const models : string [ ] = [
57- // "opencode/gpt-5",
5857 "opencode/gpt-5-codex" ,
5958 "opencode/gpt-5.1-codex" ,
6059 "opencode/claude-sonnet-4-5" ,
6160 "opencode/glm-4.6" ,
62- // "opencode/claude-sonnet-4",
63- // "opencode/claude-3-5-haiku",
64- // "opencode/claude-opus-4-1",
65- // "opencode/qwen3-coder",
66- // "opencode/grok-code",
67- // "opencode/kimi-k2",
61+ "opencode/gemini-3-pro" ,
62+ "opencode/qwen3-coder" ,
63+ "opencode/kimi-k2" ,
64+ "opencode/grok-code" ,
6865] ;
6966
7067function formatCommand ( command : string , args : string [ ] ) : string {
@@ -125,12 +122,8 @@ function logPromptResult(
125122 logs ?: string [ ] ,
126123) : void {
127124 logJson ( { info : result . info } , options ) ;
128- if ( result . parts ?. length ) {
129- return ;
130- }
131- if ( Array . isArray ( result . parts ) ) {
132- result . parts . forEach ( ( part ) => logJson ( part , options ) ) ;
133- } else {
125+
126+ if ( ! Array . isArray ( result . parts ) ) {
134127 logError (
135128 {
136129 error : "invalid_parts_array" ,
@@ -139,7 +132,11 @@ function logPromptResult(
139132 } ,
140133 options ,
141134 ) ;
135+
136+ return ;
142137 }
138+
139+ result . parts . forEach ( ( part ) => logJson ( part , options ) ) ;
143140}
144141
145142function serializeError ( error : unknown ) : Record < string , unknown > {
0 commit comments