llama-stack/llama_stack/providers/remote/inference
Ashwin Bharambe 754feba61f
feat: add a configurable category-based logger (#1352)
A self-respecting server needs good observability which starts with
configurable logging. Llama Stack had little until now. This PR adds a
`logcat` facility towards that. Callsites look like:

```python
logcat.debug("inference", f"params to ollama: {params}")
```

- the first parameter is a category. there is a static list of
categories in `llama_stack/logcat.py`
- each category can be associated with a log-level which can be
configured via the `LLAMA_STACK_LOGGING` env var.
- a value `LLAMA_STACK_LOGGING=inference=debug;server=info"` does the
obvious thing. there is a special key called `all` which is an alias for
all categories

## Test Plan

Ran with `LLAMA_STACK_LOGGING="all=debug" llama stack run fireworks` and
saw the following:


![image](https://github.com/user-attachments/assets/d24b95ab-3941-426c-9ea0-a4c62542e6f0)

Hit it with a client-sdk test case and saw this:


![image](https://github.com/user-attachments/assets/3fee8c6c-986e-4125-a09c-f5dc019682e2)
2025-03-02 18:51:14 -08:00
..
anthropic feat(providers): Groq now uses LiteLLM openai-compat (#1303) 2025-02-27 13:16:50 -08:00
bedrock feat(api): Add options for supporting various embedding models (#1192) 2025-02-20 22:27:12 -08:00
cerebras fix: register provider model name and HF alias in run.yaml (#1304) 2025-02-27 16:39:23 -08:00
databricks fix: resolve type hint issues and import dependencies (#1176) 2025-02-25 11:06:47 -08:00
fireworks feat: add a configurable category-based logger (#1352) 2025-03-02 18:51:14 -08:00
gemini feat(providers): Groq now uses LiteLLM openai-compat (#1303) 2025-02-27 13:16:50 -08:00
groq fix: register provider model name and HF alias in run.yaml (#1304) 2025-02-27 16:39:23 -08:00
nvidia chore(lint): update Ruff ignores for project conventions and maintainability (#1184) 2025-02-28 09:36:49 -08:00
ollama feat: add a configurable category-based logger (#1352) 2025-03-02 18:51:14 -08:00
openai feat(providers): Groq now uses LiteLLM openai-compat (#1303) 2025-02-27 13:16:50 -08:00
passthrough feat(api): Add options for supporting various embedding models (#1192) 2025-02-20 22:27:12 -08:00
runpod feat(api): Add options for supporting various embedding models (#1192) 2025-02-20 22:27:12 -08:00
sambanova feat(api): Add options for supporting various embedding models (#1192) 2025-02-20 22:27:12 -08:00
sample build: format codebase imports using ruff linter (#1028) 2025-02-13 10:06:21 -08:00
tgi feat(api): Add options for supporting various embedding models (#1192) 2025-02-20 22:27:12 -08:00
together feat: add a configurable category-based logger (#1352) 2025-03-02 18:51:14 -08:00
vllm chore: remove dependency on llama_models completely (#1344) 2025-03-01 12:48:08 -08:00
__init__.py impls -> inline, adapters -> remote (#381) 2024-11-06 14:54:05 -08:00