Skip to content

Model operators

Public

The Model family contains 5 operators. Direct LLM calls — responses, classification, extraction, embeddings, reranking.

Classifies text into predefined categories using an LLM.

Version 1.0.0 · Semantics passthrough · Secrets OPENROUTER_API_KEY

FieldTypeRequiredDefaultDescription
labelsstring[]yesClassification labels.
max_tokensintegerno4096
modelstringyesModel identifier (e.g. ‘deepseek/deepseek-r1’).
multi_labelbooleannofalse
stop_sequencesstring[]no
temperaturenumberno0.7
top_pnumberno
PortTypeRequiredDescription
inputstringyesInput
PortTypeRequiredDescription
outputanynoClassification
usageobjectnoUsage

Generates vector embeddings from text.

Version 1.0.0 · Semantics passthrough · Secrets OPENROUTER_API_KEY

FieldTypeRequiredDefaultDescription
dimensionsintegerno
modelstringyesEmbedding model identifier.
PortTypeRequiredDescription
inputstringyesInput
PortTypeRequiredDescription
outputnumber[]noEmbedding
usageobjectnoUsage

Extracts structured data from text using an LLM with a JSON schema.

Version 1.0.0 · Semantics passthrough · Secrets OPENROUTER_API_KEY

FieldTypeRequiredDefaultDescription
max_tokensintegerno4096
modelstringyesModel identifier (e.g. ‘deepseek/deepseek-r1’).
output_schemaobjectyesJSON Schema defining the extraction target.
stop_sequencesstring[]no
temperaturenumberno0.7
top_pnumberno
PortTypeRequiredDescription
inputstringyesInput
PortTypeRequiredDescription
outputanynoExtracted
usageobjectnoUsage

Reranks documents by relevance to a query.

Version 1.0.0 · Semantics passthrough · Visibility advanced · Secrets OPENROUTER_API_KEY

FieldTypeRequiredDefaultDescription
modelstringyes
top_kintegerno10
PortTypeRequiredDescription
documentsarrayyesDocuments
querystringyesQuery
PortTypeRequiredDescription
outputarraynoRanked

Sends a prompt to an LLM and returns generated text.

Version 1.0.0 · Semantics passthrough · Secrets OPENROUTER_API_KEY

FieldTypeRequiredDefaultDescription
max_tokensintegerno4096
modelstringyesModel identifier (e.g. ‘deepseek/deepseek-r1’).
response_format”text” | “json_object”no"text"
stop_sequencesstring[]no
system_promptstringno
temperaturenumberno0.7
top_pnumberno
PortTypeRequiredDescription
promptanyyesPrompt
PortTypeRequiredDescription
outputstringnoText
usageobjectnoUsage

Every operator above is rendered from its JSON schema in /opt/glyph/schemas/operators/:

  • schemas/operators/model.classify.json
  • schemas/operators/model.embed.json
  • schemas/operators/model.extract.json
  • schemas/operators/model.rerank.json
  • schemas/operators/model.respond.json