Another cleanup pass
This commit is contained in:
@@ -5,10 +5,16 @@ const STATE = readFileSync(
|
||||
new URL('../lib/agent-state.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
const TOOLS = readFileSync(
|
||||
new URL('../lib/agent-tools.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
const TOOLS =
|
||||
readFileSync(new URL('../lib/agent-tools.js', import.meta.url), 'utf8') +
|
||||
readFileSync(
|
||||
new URL('../lib/agent-tool-definitions.js', import.meta.url),
|
||||
'utf8'
|
||||
) +
|
||||
readFileSync(
|
||||
new URL('../lib/agent-tool-dispatch.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
const OPENAI = readFileSync(
|
||||
new URL('../lib/agent-openai.js', import.meta.url),
|
||||
'utf8'
|
||||
|
||||
@@ -14,7 +14,18 @@ const PORT_SRC = readFileSync(
|
||||
new URL('../lib/agent-grok-port.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
const TOOLS_SRC = readFileSync(new URL('../lib/agent-tools.js', import.meta.url), 'utf8')
|
||||
const TOOLS_SRC =
|
||||
readFileSync(new URL('../lib/agent-tools.js', import.meta.url), 'utf8') +
|
||||
'\n' +
|
||||
readFileSync(
|
||||
new URL('../lib/agent-tool-definitions.js', import.meta.url),
|
||||
'utf8'
|
||||
) +
|
||||
'\n' +
|
||||
readFileSync(
|
||||
new URL('../lib/agent-tool-dispatch.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
|
||||
function loadPort() {
|
||||
const sandbox = { TextDecoder, TextEncoder, Uint8Array, console }
|
||||
|
||||
@@ -2,10 +2,18 @@ import test from 'brittle'
|
||||
import { readFileSync } from 'node:fs'
|
||||
import vm from 'node:vm'
|
||||
|
||||
const CODE = readFileSync(
|
||||
new URL('../lib/agent-tools.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
const CODE =
|
||||
readFileSync(new URL('../lib/agent-tools.js', import.meta.url), 'utf8') +
|
||||
'\n' +
|
||||
readFileSync(
|
||||
new URL('../lib/agent-tool-definitions.js', import.meta.url),
|
||||
'utf8'
|
||||
) +
|
||||
'\n' +
|
||||
readFileSync(
|
||||
new URL('../lib/agent-tool-dispatch.js', import.meta.url),
|
||||
'utf8'
|
||||
)
|
||||
|
||||
function load(extra = {}) {
|
||||
const sandbox = {
|
||||
|
||||
Reference in New Issue
Block a user