feat(grpc): dev mode, agent prefix, system prompt, error UX
- gRPC dev_mode config: disables JWT auth, uses fixed dev identity - Agent prefix (agents.agent_prefix): dev agents use "dev-sol-orchestrator" to avoid colliding with production on shared Mistral accounts - Coding sessions use instructions (system prompt + coding addendum) with mistral-medium-latest for personality adherence - Conversations API: don't send both model + agent_id (422 fix) - GrpcState carries system_prompt + orchestrator_agent_id - Session.end() keeps session active for reuse (not "ended") - User messages posted as m.notice, assistant as m.text (role detection) - History loaded from Matrix room on session resume - Docker Compose local dev stack: OpenSearch 3 + Tuwunel + SearXNG - Dev config: localhost URLs, dev_mode, opensearch-init.sh for ML setup
This commit is contained in:
@@ -256,6 +256,7 @@ async fn main() -> anyhow::Result<()> {
|
||||
agent_tools,
|
||||
&state.mistral,
|
||||
&active_agents,
|
||||
&config.agents.agent_prefix,
|
||||
)
|
||||
.await
|
||||
{
|
||||
@@ -295,12 +296,16 @@ async fn main() -> anyhow::Result<()> {
|
||||
|
||||
// Start gRPC server if configured
|
||||
if config.grpc.is_some() {
|
||||
let orchestrator_id = state.conversation_registry.get_agent_id().await
|
||||
.unwrap_or_default();
|
||||
let grpc_state = std::sync::Arc::new(grpc::GrpcState {
|
||||
config: config.clone(),
|
||||
tools: state.responder.tools(),
|
||||
store: store.clone(),
|
||||
mistral: state.mistral.clone(),
|
||||
matrix: matrix_client.clone(),
|
||||
system_prompt: system_prompt_text.clone(),
|
||||
orchestrator_agent_id: orchestrator_id,
|
||||
});
|
||||
tokio::spawn(async move {
|
||||
if let Err(e) = grpc::start_server(grpc_state).await {
|
||||
|
||||
Reference in New Issue
Block a user