agentnet 0.1.11 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/llm/gemini.js +4 -0
package/package.json
CHANGED
package/src/llm/gemini.js
CHANGED
|
@@ -66,6 +66,7 @@ class GeminiLLM extends BaseLLM {
|
|
|
66
66
|
|
|
67
67
|
try {
|
|
68
68
|
const res = await client.models.generateContent(input);
|
|
69
|
+
console.log(JSON.stringify(res, null, 2))
|
|
69
70
|
logger.debug('Gemini response received', {
|
|
70
71
|
responseType: res.response?.candidates ? 'candidates' : 'unknown',
|
|
71
72
|
hasContent: !!res.response?.candidates?.[0]?.content
|
|
@@ -153,6 +154,9 @@ class GeminiLLM extends BaseLLM {
|
|
|
153
154
|
// Handle simple text response
|
|
154
155
|
logger.info('Gemini onResponse', {text: response.text !== undefined, functionCalls: response.functionCalls?.length, run: run, maxRuns: maxRuns });
|
|
155
156
|
|
|
157
|
+
if (run > 4) {
|
|
158
|
+
console.log(JSON.stringify(response, null, 2))
|
|
159
|
+
}
|
|
156
160
|
|
|
157
161
|
if (response.text !== undefined && (response.functionCalls === undefined || response.functionCalls.length === 0 || run >= maxRuns - 1) ) {
|
|
158
162
|
logger.debug('Gemini response contains text, returning directly');
|