BuildBuilt-in toolsText editor, shell and memory

Text editor, shell and memory

⚠️
Preview — this feature is being built; the design below is the spec.

Three ready-made client tools that Syntic models are tuned to use consistently: a file editor, a shell and a memory folder. You add one by type name, without writing a schema; the model calls it with fixed, documented commands; your application runs them. They are the building blocks of coding agents and long-running assistants, and they work the same way Syntic Code uses its own tools.

TypeWhat the model can do
syntic_text_editorView files and folders, create files, replace exact text, insert lines, undo.
syntic_shellRun shell commands; state carries over between calls.
syntic_memoryRead and write notes in a /memories folder that survives between conversations.

When to use them

  • Building a coding or file-handling agent: use the editor and shell instead of designing your own tools.
  • Assistants that should remember preferences and progress across sessions: use memory.

Endpoint and auth

POST https://app.syntic.ai/v1/chat/completions (and Messages), Authorization: Bearer sk_live_....

Tool definitions

FieldApplies toDetails
typeallOne of the three type names.
rooteditor, memoryOptional display path the model should treat as the top folder, for example "/workspace".
max_output_charsshellOptional. Tells the model you will truncate long output to this length.

Commands

The model’s tool call has a command field plus arguments.

syntic_text_editor

commandArgumentsYour code should return
viewpath, optional range: [start, end]File contents with line numbers, or a folder listing two levels deep.
createpath, contentConfirmation. Fail if the file exists.
replacepath, old_text, new_textConfirmation. Fail unless old_text appears exactly once.
insertpath, after_line, textConfirmation.
undopathConfirmation after restoring the previous version.

syntic_shell

commandArgumentsYour code should return
runcmd, optional timeout_secondsCombined stdout and stderr, and the exit code.
restartnoneConfirmation after starting a fresh session.

syntic_memory

commandArgumentsYour code should return
listnoneFiles under /memories.
readpathFile contents.
writepath, contentConfirmation (create or overwrite).
editpath, old_text, new_textConfirmation.
deletepathConfirmation.

Report failures as text in the tool result (“Error: old_text found 3 times”); the model corrects itself.

⚠️

These tools run on your machines. Confine the editor and memory to one folder (reject .. and absolute paths outside it), run the shell in a container or sandbox, and ask the user before destructive commands. Memory files can contain anything a user said; treat them as user data.

Examples

curl https://app.syntic.ai/v1/chat/completions \
  -H "Authorization: Bearer $SYNTIC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "Syntic Code",
    "stream": false,
    "tools": [
      { "type": "syntic_text_editor", "root": "/workspace" },
      { "type": "syntic_shell", "max_output_chars": 20000 }
    ],
    "messages": [{ "role": "user", "content": "The tests in tests/test_dates.py fail. Find the bug and fix it." }]
  }'

Errors

Unified envelope.

StatuscodeCause
400unknown_tool_typeMisspelled type name.
400duplicate_tool_typeThe same standard tool listed twice.
400tool_name_conflictA function tool uses a reserved syntic_ name.

Cost

Standard tools are free to use. Their built-in definitions add a small fixed number of input tokens (about 300 each) and are usually served from cache.

Build notes for the platform team

  • Mostly documentation plus prompt tuning: expand each type into its schema and short instructions on the server.
  • Keep command names and arguments stable; changes go behind the API version header.
  • Reserve the syntic_ prefix for built-in tools.
Was this page helpful?