=============================================================================
Date: 2025-09-28
This bundle adds Codestral support across your Umicom repos with secure key handling, C/CMake code, test scripts, and detailed documentation.
Repos covered:
- umicom-authorengine-ai (UAEngine CLI): add a Mistral backend (
llm_mistral.c) using the Chat Completions API. - umicom-studio-ide: provide a minimal FIM (Fill‑In‑the‑Middle) integration (
studio_codestral_fim.c) designed for editor autocomplete/infill. - Common scripts for environment setup and quick cURL-based tests.
Keys are never committed. Use
MISTRAL_API_KEYin your shell environment or.env.local(git‑ignored).
- Set your key:
- PowerShell (Windows):
setx MISTRAL_API_KEY "sk-..."
# restart shell/app- Bash (Linux/macOS):
echo 'export MISTRAL_API_KEY=sk-...' >> ~/.bashrc
source ~/.bashrc- Test Chat endpoint:
./scripts/test-codestral-chat.sh- Test FIM endpoint:
./scripts/test-codestral-fim.sh- Build UAEngine with Mistral backend (libcurl required):
cd umicom-authorengine-ai
mkdir -p build && cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
cmake --build . -j- Build Studio IDE backend stub (FIM demo):
cd umicom-studio-ide
mkdir -p build && cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
cmake --build . -jSee repo‑specific READMEs inside each folder for details.
third_party/api-schemas/mistral/openapi.yaml- the API contract used for docs and codegen.- Local viewers: open
umicom-authorengine-ai/docs/api/mistral/index.htmlorumicom-studio-ide/docs/api/mistral/index.html. - Sync script:
./scripts/sync-mistral-schema.sh(or.ps1). - Codegen scripts (optional):
./scripts/generate/openapi_codegen_c.sh/.ps1./scripts/generate/openapi_codegen_cpp.sh/.ps1
Codegen is optional - our hand-written
libcurlbackends (Chat + FIM) are already included and heavily commented.