Skip to content

Commit

Permalink
feat(guide): add light version to extract title
Browse files Browse the repository at this point in the history
  • Loading branch information
snowyu committed Sep 1, 2024
1 parent 0aa7d96 commit be20e9b
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions guide/extract_title.ai.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
input:
- content # The content to titleify
- len: {type: "number"} # the optional max length of the title. It is not precise, just an approximate number.
- temperature # the optional temperature of the LLM.
len: -1 # the default max length of the title, -1 means no limit
temperature: 0.01 # the default temperature of the LLM.
---
- system: |-
Extract the title from the markdown content provided by the user.
{%- if len and len > 0 -%}
Keep the title within {{len}} characters.
{% endif %}
Output the title ONLY. DO NOT EXPLAIN.
- user: |-
{{content}}
- assistant: "[[titles:max_tokens=len, temperature]]"

0 comments on commit be20e9b

Please sign in to comment.