KosmoKrator

ai

Together AI CLI for AI Agents

Use the Together AI CLI from KosmoKrator to call Together AI tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

7 functions 6 read 1 write API key auth

Together AI CLI Setup

Together AI can be configured headlessly with `kosmokrator integrations:configure together-ai`.

# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure together-ai --set api_key="$TOGETHER_AI_API_KEY" --enable --read allow --write ask --json
kosmokrator integrations:doctor together-ai --json
kosmokrator integrations:status --json

Credentials

Authentication type: API key api_key. Configure credentials once, then use the same stored profile from scripts, coding CLIs, Lua code mode, and the MCP gateway.

KeyEnv varTypeRequiredLabel
api_key TOGETHER_AI_API_KEY Secret secret yes API Key
url TOGETHER_AI_URL URL url no API Base URL

Call Together AI Headlessly

Use the generic call form when another coding CLI or script needs a stable universal interface.

kosmo integrations:call together-ai.togetherai_list_models '{}' --json

Use the provider shortcut form for shorter human-facing commands.

kosmo integrations:together-ai togetherai_list_models '{}' --json

Agent Discovery Commands

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

kosmo integrations:docs together-ai --json
kosmo integrations:docs together-ai.togetherai_list_models --json
kosmo integrations:schema together-ai.togetherai_list_models --json
kosmo integrations:search "Together AI" --json
kosmo integrations:list --json

All CLI Functions

Every function below can be called headlessly. The generic form is stable across all integrations; the provider shortcut is shorter but specific to Together AI.

together-ai.togetherai_list_models

Read read

List all available AI models on Together AI, including open-source and fine-tuned models. Returns model IDs, types, pricing, and capabilities.

Parameters
none

Generic CLI call

kosmo integrations:call together-ai.togetherai_list_models '{}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_list_models '{}' --json

together-ai.togetherai_create_completion

Write write

Create a chat completion using a Together AI model. Send a conversation with messages and receive a generated response. Supports models like Llama, Mixtral, Qwen, DBRX, and more.

Parameters
model, messages, max_tokens, temperature, top_p, top_k, frequency_penalty, presence_penalty, stop

Generic CLI call

kosmo integrations:call together-ai.togetherai_create_completion '{"model":"example_model","messages":"example_messages","max_tokens":1,"temperature":1,"top_p":1,"top_k":1,"frequency_penalty":1,"presence_penalty":1}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_create_completion '{"model":"example_model","messages":"example_messages","max_tokens":1,"temperature":1,"top_p":1,"top_k":1,"frequency_penalty":1,"presence_penalty":1}' --json

together-ai.togetherai_list_fine_tunes

Read read

List all fine-tuning jobs on Together AI. Returns job IDs, status, base model, training file, and creation timestamps.

Parameters
none

Generic CLI call

kosmo integrations:call together-ai.togetherai_list_fine_tunes '{}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_list_fine_tunes '{}' --json

together-ai.togetherai_get_fine_tune

Read read

Get details of a specific fine-tuning job on Together AI. Returns status, training progress, hyperparameters, and the output model ID once complete.

Parameters
fine_tune_id

Generic CLI call

kosmo integrations:call together-ai.togetherai_get_fine_tune '{"fine_tune_id":"example_fine_tune_id"}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_get_fine_tune '{"fine_tune_id":"example_fine_tune_id"}' --json

together-ai.togetherai_list_files

Read read

List all files uploaded to Together AI. Returns file IDs, filenames, sizes, and purposes (e.g. fine-tune training data, results).

Parameters
none

Generic CLI call

kosmo integrations:call together-ai.togetherai_list_files '{}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_list_files '{}' --json

together-ai.togetherai_get_file

Read read

Get details of a specific file on Together AI. Returns file metadata including name, size, purpose, and creation date.

Parameters
file_id

Generic CLI call

kosmo integrations:call together-ai.togetherai_get_file '{"file_id":"example_file_id"}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_get_file '{"file_id":"example_file_id"}' --json

together-ai.togetherai_get_current_user

Read read

Get the authenticated Together AI user's account information, including name, email, and plan details.

Parameters
none

Generic CLI call

kosmo integrations:call together-ai.togetherai_get_current_user '{}' --json

Provider shortcut

kosmo integrations:together-ai togetherai_get_current_user '{}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

together-ai.togetherai_list_models

List all available AI models on Together AI, including open-source and fine-tuned models. Returns model IDs, types, pricing, and capabilities.

Operation
Read read
Schema command
kosmo integrations:schema together-ai.togetherai_list_models --json
ParameterTypeRequiredDescription
No parameters.

together-ai.togetherai_create_completion

Create a chat completion using a Together AI model. Send a conversation with messages and receive a generated response. Supports models like Llama, Mixtral, Qwen, DBRX, and more.

Operation
Write write
Schema command
kosmo integrations:schema together-ai.togetherai_create_completion --json
ParameterTypeRequiredDescription
model string yes The model ID to use (e.g. "meta-llama/Llama-3.3-70B-Instruct-Turbo", "mistralai/Mixtral-8x7B-Instruct-v0.1").
messages array yes Array of message objects with "role" (system, user, assistant) and "content" fields.
max_tokens integer no Maximum number of tokens to generate in the response.
temperature number no Sampling temperature (0.0–2.0). Higher values increase randomness. Defaults to 0.7.
top_p number no Nucleus sampling threshold (0.0–1.0). Defaults to 0.7.
top_k integer no Top-k sampling parameter. Limits tokens considered at each step.
frequency_penalty number no Penalize tokens based on frequency (-2.0 to 2.0).
presence_penalty number no Penalize tokens based on presence (-2.0 to 2.0).
stop array no Array of stop sequences. Generation stops when any sequence is encountered.

together-ai.togetherai_list_fine_tunes

List all fine-tuning jobs on Together AI. Returns job IDs, status, base model, training file, and creation timestamps.

Operation
Read read
Schema command
kosmo integrations:schema together-ai.togetherai_list_fine_tunes --json
ParameterTypeRequiredDescription
No parameters.

together-ai.togetherai_get_fine_tune

Get details of a specific fine-tuning job on Together AI. Returns status, training progress, hyperparameters, and the output model ID once complete.

Operation
Read read
Schema command
kosmo integrations:schema together-ai.togetherai_get_fine_tune --json
ParameterTypeRequiredDescription
fine_tune_id string yes The fine-tuning job ID (e.g. "ft-abc123").

together-ai.togetherai_list_files

List all files uploaded to Together AI. Returns file IDs, filenames, sizes, and purposes (e.g. fine-tune training data, results).

Operation
Read read
Schema command
kosmo integrations:schema together-ai.togetherai_list_files --json
ParameterTypeRequiredDescription
No parameters.

together-ai.togetherai_get_file

Get details of a specific file on Together AI. Returns file metadata including name, size, purpose, and creation date.

Operation
Read read
Schema command
kosmo integrations:schema together-ai.togetherai_get_file --json
ParameterTypeRequiredDescription
file_id string yes The file ID to retrieve.

together-ai.togetherai_get_current_user

Get the authenticated Together AI user's account information, including name, email, and plan details.

Operation
Read read
Schema command
kosmo integrations:schema together-ai.togetherai_get_current_user --json
ParameterTypeRequiredDescription
No parameters.

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.