honcho: enable OpenAI embeddings for conclusion vectorisation

- Add vault_honcho_openai_api_key (embeddings-only, Honcho-scoped)
- Inject OPENAI_API_KEY + LLM_OPENAI_API_KEY into api + deriver containers
- Flip honcho_embed_messages default to true now that embeddings have a provider
- Parameterise EMBEDDING__MODEL_CONFIG__{TRANSPORT,MODEL,BASE_URL} so we can
  later swap to a local OpenAI-compatible embedder (e.g. Ollama on
  astro-orbiter post-rebuild) with a single defaults change.

Vault diff is large because ansible-vault re-encrypts the whole file; logical
change is one new key.
This commit is contained in:
Hermes Agent service account
2026-05-31 22:29:03 -05:00
parent bd100c15e7
commit 23612a38f2
4 changed files with 450 additions and 396 deletions

View File

@@ -28,6 +28,14 @@ Environment=AUTH_JWT_SECRET={{ honcho_jwt_secret }}
Environment=LLM_ANTHROPIC_API_KEY={{ honcho_anthropic_api_key }}
{% endif %}
# OpenAI key — used only by the embedding subsystem. Always present so
# that conclusion vectorisation and any later semantic-search path works
# regardless of which provider serves LLM completions.
{% if honcho_openai_api_key | length > 0 %}
Environment=LLM_OPENAI_API_KEY={{ honcho_openai_api_key }}
Environment=OPENAI_API_KEY={{ honcho_openai_api_key }}
{% endif %}
# -- Deriver subsystem ------------------------------------------------------
Environment=DERIVER_FLUSH_ENABLED={{ honcho_deriver_flush_enabled | string | lower }}
Environment=DERIVER_MODEL_CONFIG__TRANSPORT={{ honcho_llm_transport }}
@@ -49,8 +57,13 @@ Environment=DIALECTIC_LEVELS__high__MODEL_CONFIG__MODEL={{ honcho_dialectic_mode
Environment=DIALECTIC_LEVELS__max__MODEL_CONFIG__TRANSPORT={{ honcho_llm_transport }}
Environment=DIALECTIC_LEVELS__max__MODEL_CONFIG__MODEL={{ honcho_dialectic_model }}
# -- Embeddings (Anthropic has no embed API; off by default) ----------------
# -- Embeddings (text-embedding-3-small via OpenAI by default) --------------
Environment=EMBED_MESSAGES={{ honcho_embed_messages | string | lower }}
Environment=EMBEDDING__MODEL_CONFIG__TRANSPORT={{ honcho_embedding_transport }}
Environment=EMBEDDING__MODEL_CONFIG__MODEL={{ honcho_embedding_model }}
{% if honcho_embedding_base_url | length > 0 %}
Environment=EMBEDDING__MODEL_CONFIG__BASE_URL={{ honcho_embedding_base_url }}
{% endif %}
# -- Vector store -----------------------------------------------------------
Environment=VECTOR_STORE_TYPE=pgvector