Skip to main content

llm-alias-options

LLM plugin to save prompt options alongside an alias.

Built for llm version 0.28.

This plugin allows you to save default prompt options (like temperature, max_tokens, etc.) with an alias, so they are automatically applied when you use that alias.

Installation

Install this plugin in the same environment as LLM:

llm install llm-alias-options

Usage

You can save default prompt options with an alias using the -o or --option flag with llm aliases set:

llm aliases set creative gpt-4o -o temperature 0.9

Now, whenever you use the creative alias, the temperature=0.9 option will be applied automatically:

llm -m creative "Write a story"

The options you specify on the command line will override the saved alias options:

llm -m creative -o temperature 0.5 "Write a story"

Listing aliases with options

To see which aliases have options configured, use the --options flag:

llm aliases list --options

Or just:

llm aliases --options

Output:

creative: gpt-4o
  Options:
    temperature: 0.9

You can also get this information in JSON format:

llm aliases --options --json

How it works

This plugin monkeypatches the core llm alias handling to support a dictionary format in aliases.json. It also wraps the prompt and chat commands to intercept the model ID and inject the saved options before the command executes.

Metadata

Release files for llm-alias-options 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llm-alias-options 0.1.1
File Size Uploaded Provenance
llm_alias_options-0.1.1.tar.gz 6.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for llm-alias-options 0.1.1
File Interpreter ABI Platform
llm_alias_options-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 10.9 kB

Release files / llm_alias_options-0.1.1.tar.gz

Download URL llm_alias_options-0.1.1.tar.gz
Size 6.4 kB
Tags Source
SHA-256 checksum
How to use checksums
36ba0b23cf097c9bcd92c924fd8378f74c7fe5e0b3fc8677b6f13685276aeabe
BLAKE2b-256 checksum
How to use checksums
e307a73184eafc0a26b01dcb6206c254335d7ed8e146bf70e21b66fb0d9ac85e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.8

Release files / llm_alias_options-0.1.1-py3-none-any.whl

Download URL llm_alias_options-0.1.1-py3-none-any.whl
Size 4.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fa405f15c16749f67a6fcee6f250b9c1cbb39886e63bd33487b5d186b1ae7bb9
BLAKE2b-256 checksum
How to use checksums
f864fcc7786f5fabcf635a95dab7ac7244a1cf5be4cd8273e29124ee3916e6ae
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.8

Security for llm-alias-options 0.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files No provenance

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