Runner that provisions Azure OpenAI assistants from YAML configs
This project has been archived.
The maintainers of this project have marked this project as archived. No new releases are expected.
Project description
LMSpace MVP
The LMSpace MVP provisions Azure OpenAI assistants from YAML config files. Each config describes a custom GPT-style agent with instructions and knowledge-base sources. The runner downloads the referenced files, uploads them to Azure OpenAI using the Assistants API (file search), and optionally registers a Microsoft Agent Framework agent when the framework is available.
The project uses uv for dependency and environment management.
Repository Layout
src/lmspace/- Package sourcestests/- Unit testsconfigs/- Example YAML configsdocs/- Design and planning documents
Prerequisites
- Python 3.12+
- uv installed locally (
pip install uv) - Azure OpenAI resource with Assistants API v2 enabled
- Optional: Microsoft Agent Framework preview packages
Before provisioning real assistants, set the following environment variables:
AZURE_OPENAI_ENDPOINTAZURE_OPENAI_API_VERSIONAZURE_OPENAI_DEPLOYMENT_NAMEAZURE_OPENAI_API_KEY(or rely on Azure AD withDefaultAzureCredential)
Optional environment variables:
GITHUB_TOKENfor private GitHub file downloadsLMSPACE_VECTOR_PREFIXto customize vector store namesLMSPACE_LOG_LEVELfor logging (defaultinfo)
Getting Started
# Create the environment using uv
uv venv
# Install the package in editable mode with development tools
uv pip install -e . --extra dev
# Provision assistants from a config file or directory (dry-run shown)
lmspace --dry-run configs/sample-agent.yaml
Run without --dry-run after configuring Azure credentials to perform real provisioning.
YAML Config Format
name: SampleAgent
instructions: |
You are a helpful assistant that answers questions about the example files.
urls:
- https://raw.githubusercontent.com/github/gitignore/main/Python.gitignore
Each urls entry should point to a text or binary document Azure OpenAI accepts for file search. The runner downloads the files, uploads them to Azure, creates a vector store, and wires it into a new assistant using your deployment.
Development
# Install deps (from repo root)
uv pip install -e . --extra dev
# Run tests
uv run --extra dev pytest
The code lives under src/lmspace. Key modules:
config.py- Validates YAML configsfetcher.py- Downloads remote knowledge sourcesazure.py- Wraps Azure OpenAI assistant provisioningrunner.py- Glues everything togethercli.py- Command-line entry point
Microsoft Agent Framework Integration
If the agent_framework preview package is installed, the runner attempts to create a matching Agent Framework agent via AzureOpenAIResponsesClient. When the package is absent, the MVP logs the omission and still provisions the Azure OpenAI assistant.
Testing Notes
Unit tests cover YAML parsing, remote fetch behaviour, and runner orchestration. Azure calls are mocked by injecting stub services, so tests run without Azure credentials.
Next Steps
- Add richer error handling and telemetry around Azure operations.
- Persist vector store and assistant identifiers for incremental updates.
- Extend the runner to handle incremental syncs and deletions.
- Package and publish to PyPI once the Agent Framework dependencies stabilise.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file lmspace-0.1.0.tar.gz.
File metadata
- Download URL: lmspace-0.1.0.tar.gz
- Upload date:
- Size: 6.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a6f8ff5f0c82b49a14ba9dfe99f128ee108b277f845dd33b444e30ab3a4843fd
|
|
| MD5 |
269fb7efbebcf060b0a265d09b5261c9
|
|
| BLAKE2b-256 |
27c857f6d1de72af26f6979c551173e832901fc62b67db6e29c410dc9cd660a6
|
File details
Details for the file lmspace-0.1.0-py3-none-any.whl.
File metadata
- Download URL: lmspace-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b86b1d97ebfa7fb7276724f9bb5d2f245e6ce9e49a543bf2b166b530f9b441a1
|
|
| MD5 |
4a6cd174f209fa663d804c2085b814cb
|
|
| BLAKE2b-256 |
e94fa8b5282649dcfdf364dd9575c4e76c0d7113777f12728029fa64a8f1503c
|