Commit d1df2e4
committed
feat: split API and provider specs into separate llama-stack-api pkg
Extract API definitions, models, and provider specifications into a
standalone llama-stack-api package that can be published to PyPI
independently of the main llama-stack server.
Motivation
External providers currently import from llama-stack, which overrides
the installed version and causes dependency conflicts. This separation
allows external providers to:
- Install only the type definitions they need without server dependencies
- Avoid version conflicts with the installed llama-stack package
- Be versioned and released independently
This enables us to re-enable external provider module tests that were
previously blocked by these import conflicts.
Changes
- Created llama-stack-api package with minimal dependencies (pydantic, jsonschema)
- Moved APIs, models, providers datatypes, strong_typing, and schema_utils
- Updated all imports from llama_stack.* to llama_stack_api.*
- Preserved git history using git mv for moved files
- Configured local editable install for development workflow
- Updated linting and type-checking configuration for both packages
- Rebased on top of upstream src/ layout changes
Testing
Package builds successfully and can be imported independently.
All pre-commit hooks pass with expected exclusions maintained.
Next Steps
- Publish llama-stack-api to PyPI
- Update external provider dependencies
- Re-enable external provider module tests
Signed-off-by: Charlie Doern <[email protected]>1 parent 1c9a31d commit d1df2e4
File tree
457 files changed
+1499
-1177
lines changed- .github/workflows
- docs
- docs
- building_applications
- concepts/apis
- distributions
- providers
- external
- vector_io
- openapi_generator
- pyopenapi
- scripts
- src
- llama-stack-api
- llama_stack_api
- apis
- agents
- batches
- benchmarks
- common
- conversations
- datasetio
- datasets
- eval
- files
- inference
- inspect
- models
- post_training
- prompts
- providers
- safety
- scoring_functions
- scoring
- shields
- synthetic_data_generation
- telemetry
- tools
- vector_io
- vector_stores
- core
- telemetry
- models
- llama
- llama3_1
- llama3_2
- llama3_3
- llama3
- multimodal
- prompt_templates
- quantization
- llama4
- prompt_templates
- quantization
- vision
- resources
- providers
- utils
- vector_io
- strong_typing
- llama_stack
- cli/stack
- core
- conversations
- prompts
- routers
- routing_tables
- server
- distributions
- dell
- meta-reference-gpu
- open-benchmark
- postgres-demo
- starter
- providers
- inline
- agents/meta_reference
- responses
- batches/reference
- datasetio/localfs
- eval/meta_reference
- files/localfs
- inference
- meta_reference
- sentence_transformers
- post_training
- common
- huggingface
- recipes
- torchtune
- common
- recipes
- safety
- code_scanner
- llama_guard
- prompt_guard
- scoring
- basic
- scoring_fn
- fn_defs
- braintrust
- scoring_fn/fn_defs
- llm_as_judge
- scoring_fn
- fn_defs
- tool_runtime/rag
- vector_io
- chroma
- faiss
- milvus
- qdrant
- sqlite_vec
- registry
- remote
- datasetio
- huggingface
- nvidia
- eval/nvidia
- files/s3
- inference
- anthropic
- azure
- bedrock
- cerebras
- databricks
- fireworks
- gemini
- groq
- llama_openai_compat
- nvidia
- ollama
- openai
- passthrough
- runpod
- sambanova
- tgi
- together
- vertexai
- vllm
- watsonx
- post_training/nvidia
- safety
- bedrock
- nvidia
- sambanova
- tool_runtime
- bing_search
- brave_search
- model_context_protocol
- tavily_search
- wolfram_alpha
- vector_io
- chroma
- milvus
- pgvector
- qdrant
- weaviate
- utils
- common
- files
- inference
- kvstore/sqlite
- memory
- responses
- scoring
- sqlstore
- tools
- tests
- external/llama-stack-api-weather/src/llama_stack_api_weather
- integration
- agents
- batches
- inference
- post_training
- responses/recordings
- safety
- telemetry
- tool_runtime
- vector_io
- unit
- conversations
- core
- routers
- distribution
- routers
- files
- models
- llama
- llama3
- providers
- agents
- meta_reference
- fixtures
- agent
- batches
- files
- inference
- inline/agents/meta_reference/responses
- nvidia
- utils
- inference
- memory
- vector_io
- rag
- registry
- server
- tools
- utils
- inference
- responses
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
457 files changed
+1499
-1177
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
33 | 37 | | |
34 | | - | |
35 | | - | |
| 38 | + | |
36 | 39 | | |
37 | | - | |
| 40 | + | |
38 | 41 | | |
39 | | - | |
| 42 | + | |
40 | 43 | | |
41 | 44 | | |
42 | 45 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
| 45 | + | |
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
83 | | - | |
| 83 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
295 | 295 | | |
296 | 296 | | |
297 | 297 | | |
298 | | - | |
| 298 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
61 | | - | |
| 61 | + | |
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| |||
151 | 151 | | |
152 | 152 | | |
153 | 153 | | |
154 | | - | |
| 154 | + | |
155 | 155 | | |
156 | 156 | | |
157 | 157 | | |
158 | 158 | | |
159 | | - | |
| 159 | + | |
160 | 160 | | |
161 | 161 | | |
162 | 162 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
| 68 | + | |
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
83 | | - | |
| 83 | + | |
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
153 | 153 | | |
154 | 154 | | |
155 | 155 | | |
156 | | - | |
| 156 | + | |
157 | 157 | | |
158 | 158 | | |
159 | 159 | | |
| |||
358 | 358 | | |
359 | 359 | | |
360 | 360 | | |
361 | | - | |
| 361 | + | |
362 | 362 | | |
363 | 363 | | |
364 | 364 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
0 commit comments