配方推荐与目录
POSThttps://api.minih3.dev/v1/tools/recipes-v1
用途:不带 action:和以前一样,列出 adapt-v1 旧的单条 recipe 可用的配方(只有 id 和名字),可选按 dimension、genre、stage 筛选;还没有配方库时返回空列表。
action: "recommend":按一条拉片(breakdown_id,breakdown-v1 的 bi_…)推荐配方包(按题材,最多 3 个,整包用)和通用配方(按改编步骤 adapt.outline / adapt.script / adapt.shots,每步最多 3 条)。每条只有编号、版本、名称、一句话(note)、效果(effect)、推荐理由(why)、会作用到的镜头号(anchors)和能用在哪种改编(usable_in),没有配方内容。model(出片模型)不带时只推和出片模型无关的配方。pack_id 指定按哪个包补缺(none = 不按包);不带时按排第一的包补缺(gap_pack),包已经管到的通用配方不再推荐,推荐的带 fills。
action: "list":配方目录(recipes 和官方 packs),可按 library、step、tag 筛选。带 action 时 dimension、genre、stage 不起作用。
用户确认的配方用 adapt-v1 stage: "intake" 的 answers.recipes 发回(见 adapt-v1)。配方内容永远不出服务器。
计费:免费。规则计算,不调模型,马上返回。
参数
| 名称 | 位置 | 类型 | 必填 | 说明 |
|---|---|---|---|---|
X-MiniH3-Skill-Version | header | string | 否 | 你在用的技能包版本号(SKILL.md 和包里的 VERSION 文件写着,每次升级加一;当前是 |
action | body | string | 否 | 不带 = 旧的单条配方目录 recommendlist |
breakdown_id | body | string | 否 | recommend 必填:breakdown-v1 的 bi_…(不是你的拉片回 404 record_not_found) |
model | body | string | 否 | recommend 可选:出片模型;不带只推和出片模型无关的 h3seedancegrokminimax |
pack_id | body | string | 否 | recommend 可选:按这个包补缺;none = 不按包 |
library | body | string | 否 | list 可选 generalpack |
step | body | string | 否 | list 可选 adapt.outlineadapt.scriptadapt.shots |
tag | body | string | 否 | list 可选 asset_extractasset_genscriptshotscameraactiondialoguepacingother |
report_language | body | string | 否 | 名称、说明、效果的语言 enzh |
dimension | body | string | 否 | 不带 action 时 genre_promisefirst_cardcharacter_relationshipplot_causalityemotion_curvepacingshot_directionsound_narrativevisual_styleasset_continuityedit_audiovisualscene_dialogueworld_rules |
genre | body | string | 否 | 不带 action 时 |
stage | body | string | 否 | 不带 action 时 outlinescriptshots |
代码示例
curl -X POST "https://api.minih3.dev/v1/tools/recipes-v1" \
-H "Authorization: Bearer $MINIH3_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"action": "recommend",
"breakdown_id": "bi_xxxxxxxxxxxxxxxxxxxxxxxx",
"model": "h3",
"report_language": "zh"
}'在线试调
只存在这个浏览器标签页里(sessionStorage),直接发给 api.minih3.dev,不经过本站服务器。
填上 key 才能发送。响应
200
推荐、目录或旧的单条配方目录
{
"action": "recommend",
"breakdown_id": "bi_xxxxxxxxxxxxxxxxxxxxxxxx",
"model": "h3",
"packs": [
{
"id": "pk-…",
"version": "…-v2",
"name": "(包名 / pack name)",
"note": "",
"genres": [
"revenge"
],
"recipe_count": 12,
"points": {
"adapt.outline": 5,
"adapt.script": 6,
"adapt.shots": 4
}
}
],
"gap_pack": {
"id": "pk-…",
"version": "…-v2"
},
"steps": {
"adapt.outline": [],
"adapt.script": [],
"adapt.shots": [
{
"id": "00000000-0000-5000-8000-000000000000",
"version": "1-abcdef12",
"library": "general",
"name": "(名称 / name)",
"note": "(一句话 / one line)",
"effect": "(效果 / effect)",
"steps": {
"adapt.shots": "inject"
},
"stage_scope": [
"adapt.shots"
],
"tags": [
"camera"
],
"genres": [],
"models": [
"generic"
],
"changes_plot": false,
"evidence": "doc",
"status": "candidate",
"usable_in": [
"adapted_changed",
"adapted_kept",
"original"
],
"point": "adapt.shots",
"mode": "inject",
"why": {
"appeal": "suspense",
"shot_features": {
"static_heavy": [
1,
2,
3
]
}
},
"anchors": [
1,
2,
3
],
"fills": [
"camera"
]
}
]
},
"matched": {
"genres": [
"revenge"
],
"appeals": [
"suspense"
],
"narrative": "dialogue",
"shot_features": {
"static_heavy": 30
}
},
"limits": {
"per_step": 3,
"packs": 3
},
"next": {
"hint": "…"
}
}400
错误
404
错误