Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Friday Framework LLM

friday-framework-llm is Friday's LiteLLM-backed chat and embedding package. Version 0.1.0a1 adds provider-neutral reasoning and sampling contracts while keeping the 0.1.0a0 completion APIs compatible for one deprecation window.

Install

pip install friday-framework-llm==0.1.0a1

The import package is friday_llm. This alpha pins litellm==1.94.1 because the observed provider translation is part of the tested contract.

Typed Completion

New integrations should declare transport identity, model identity, and generation intent separately:

from friday_llm import (
    ChatCompletionRequest,
    GenerationOverrides,
    LiteLLMService,
    ModelTarget,
    ReasoningConfig,
    ReasoningMode,
    SamplingConfig,
    TransportTarget,
)

service = LiteLLMService(
    model_name="openai/qwen3.8-27b-mlx",
    api_key="lm-studio",
    api_base="http://127.0.0.1:1234/v1",
    transport_target=TransportTarget(
        provider="openai_compatible",
        dialect="openai_chat_completions",
        serving_engine="lm_studio",
    ),
    model_target=ModelTarget(
        model_id="qwen3.8-27b-mlx",
        family="qwen3_8",
        revision="your-captured-model-revision",
    ),
)

response = await service.chat_completion_request(
    ChatCompletionRequest(
        messages=({"role": "user", "content": "Use a synthetic prompt."},),
        overrides=GenerationOverrides(
            reasoning=ReasoningConfig(
                mode=ReasoningMode.ENABLED,
                effort="medium",
            ),
            sampling=SamplingConfig(temperature=0.3, top_k=20),
            max_tokens=256,
        ),
    )
)

Omitted request fields inherit service defaults. An explicit None clears a service default and delegates that field to the provider. The typed API does not inject the legacy temperature=0.7 default.

Typed Streaming

chat_completion_events() separates text, reasoning, tool fragments, complete tool calls, usage, finish state, and diagnostic-safe errors. It never mixes reasoning text into final text or tool arguments.

async for event in service.chat_completion_events(request):
    if event.type == "text_delta":
        print(event.text, end="")
    elif event.type == "tool_call_complete":
        dispatch(event.name, event.arguments)

Release-One Support Matrix

Axis Built-in normalized profile
Endpoint dialect OpenAI-compatible Chat Completions
Transport litellm.acompletion
Serving engine LM Studio
Model family Qwen3.8
Evidence target local alias qwen3.8-27b-mlx
Reasoning provider default, enabled, disabled; effort xhigh, medium, low; preserve
Sampling temperature, top-p, top-k, min-p, presence/frequency penalty, repetition penalty
Unsupported Qwen3.8 reasoning token budget

OpenAI Responses, LM Studio native REST, Anthropic-native, Gemini, Ollama, DeepSeek, Moonshot, Bedrock, vLLM, and SGLang normalized profiles are deferred. Legacy LiteLLM routing remains available, but Friday does not advertise typed reasoning controls for an unregistered target composition.

Model-card sampling recommendations are not Friday defaults. Typed, namespaced LMStudioQwenOptions exist only for the registered profile and cannot set credentials, URLs, messages, tools, telemetry, retries, timeouts, or arbitrary extra_body fields.

Assurance And Privacy

Friday uses these evidence terms precisely:

  • requested: supplied by the caller;
  • resolved: accepted after merge and capability validation;
  • emitted: present in captured outbound HTTP JSON;
  • acknowledged: confirmed by provider or server metadata;
  • behaviorally_observed: supported by a bounded controlled comparison.

Emitted does not mean effective. Assurance metadata contains bounded field and profile names, capability provenance, and the LiteLLM version. It does not contain prompts, tool arguments, credentials, response bodies, or reasoning text. preserve_thinking controls provider chat-template replay; it does not grant Friday permission to persist or log reasoning.

Legacy Migration

chat_completion() and text-only chat_completion_stream() retain their current signatures and return shapes. The legacy default still disables thinking and still supplies temperature=0.7.

Old input 0.1.0a1 behavior Migration
thinking_enabled omitted legacy disabled behavior move new callers to ReasoningMode.AUTO or an explicit mode
thinking_enabled=False disabled plus DeprecationWarning use ReasoningConfig(mode="disabled")
thinking_enabled=True enabled intent plus DeprecationWarning declare an execution target and use typed reasoning
contradictory old/new values configuration error before I/O keep one source of truth

Importing friday_llm no longer changes LiteLLM's process-global drop_params or modify_params policy. Compatibility settings are scoped to individual legacy calls; typed calls use strict preflight validation.

LM Studio 0.4.x accepts only string-form tool-choice values. For a normalized named function choice, the private LM Studio adapter exposes only the selected function schema and emits required, preserving exact-function semantics without adding an LM Studio field to the public request model. A missing or ambiguous selected schema fails before external I/O.

Live LM Studio Evidence Lane

The default tests never contact LM Studio. To opt in, load the exact model, record its revision/fingerprint, then run:

FRIDAY_LLM_LIVE=1 \
FRIDAY_LLM_LIVE_REVISION='<captured revision>' \
FRIDAY_LLM_LIVE_MODEL='qwen3.8-27b-mlx' \
uv run pytest -q packages/friday-llm/tests_llm/test_live_lmstudio.py

The live lane is a release gate, not ordinary CI. Record LM Studio version, architecture, quantization, alias, chat template, context length, and server settings alongside its results.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

friday_framework_llm-0.1.0a1.tar.gz (54.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

friday_framework_llm-0.1.0a1-py3-none-any.whl (41.2 kB view details)

Uploaded Python 3

File details

Details for the file friday_framework_llm-0.1.0a1.tar.gz.

File metadata

  • Download URL: friday_framework_llm-0.1.0a1.tar.gz
  • Upload date:
  • Size: 54.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.10

File hashes

Hashes for friday_framework_llm-0.1.0a1.tar.gz
Algorithm Hash digest
SHA256 7d844bf6e7b247d509d1e61ad6dcb61265de19fbaba250f13fd32ba4e5ed21bd
MD5 dfb55379af8c20320beea9756c727c86
BLAKE2b-256 09f5aeef7f0f0e903952ff3917df951d5f0b9c4e43866ddc8ad3aa912fa53a82

See more details on using hashes here.

File details

Details for the file friday_framework_llm-0.1.0a1-py3-none-any.whl.

File metadata

File hashes

Hashes for friday_framework_llm-0.1.0a1-py3-none-any.whl
Algorithm Hash digest
SHA256 c536c38456055078fe97b36bd9dd38f7822786f3cdc1d9114591d8abee42ef43
MD5 05d2eab31db35d7ebf05cdc533aa0e4b
BLAKE2b-256 e3b4fc81a73bc7d7e11529bfe4ae7cf6f3a3c4e494acd76a9a9529eaa87f8017

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.0a1 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page