Documentation Index Fetch the complete documentation index at: https://www.truefoundry.com/llms.txt
Use this file to discover all available pages before exploring further.
Methods
Get a prompt by its ID. Parameters Returns Usage from truefoundry import TrueFoundry
client = TrueFoundry(
api_key = "YOUR_API_KEY" ,
base_url = "https://yourhost.com/path/to/api" ,
)
client.prompts.get(
id = "id_value" ,
)
Delete a prompt by its ID. Parameters Returns Usage from truefoundry import TrueFoundry
client = TrueFoundry(
api_key = "YOUR_API_KEY" ,
base_url = "https://yourhost.com/path/to/api" ,
)
client.prompts.delete(
id = "id_value" ,
)
List prompts with optional filtering by FQN, ML Repo, or name. Parameters Fully qualified name to filter prompts by (format: ‘chat_prompt://’)
ID of the ML Repo to filter prompts by
Name of the prompt to filter by
Number of prompts to skip for pagination
Maximum number of prompts to return
Whether to include prompts that have no versions
Returns Usage from truefoundry import TrueFoundry
client = TrueFoundry(
api_key = "YOUR_API_KEY" ,
base_url = "https://yourhost.com/path/to/api" ,
)
client.prompts.list(
fqn = "value" ,
ml_repo_id = "value" ,
name = "value" ,
offset = 10 ,
limit = 10 ,
include_empty_prompts = "value" ,
)
# Iterate through results
for item in response:
print (item.name)
# Or paginate page by page
for page in response.iter_pages():
for item in page:
print (item.name)
Create or update a prompt version. Parameters manifest
ChatPromptManifest
required
Returns Usage from truefoundry import TrueFoundry
client = TrueFoundry(
api_key = "YOUR_API_KEY" ,
base_url = "https://yourhost.com/path/to/api" ,
)
client.prompts.create_or_update(
manifest ={ "key" : "value" },
)
Get Prompt by FQN. Parameters Returns Usage from truefoundry import TrueFoundry
client = TrueFoundry(
api_key = "YOUR_API_KEY" ,
base_url = "https://yourhost.com/path/to/api" ,
)
client.prompts.get_by_fqn(
fqn = "value" ,
)