feat(tests): add "advanced" field to all template objects in test files
feat(tests): add 'advanced' field to template properties in test files
This commit is contained in:
parent
0fd8f73c08
commit
f3d385b8e5
4 changed files with 105 additions and 0 deletions
|
|
@ -27,6 +27,7 @@ def test_prompt_template(client: TestClient):
|
|||
"name": "input_variables",
|
||||
"type": "str",
|
||||
"list": True,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["output_parser"] == {
|
||||
"required": False,
|
||||
|
|
@ -37,6 +38,7 @@ def test_prompt_template(client: TestClient):
|
|||
"name": "output_parser",
|
||||
"type": "BaseOutputParser",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["partial_variables"] == {
|
||||
"required": False,
|
||||
|
|
@ -47,6 +49,7 @@ def test_prompt_template(client: TestClient):
|
|||
"name": "partial_variables",
|
||||
"type": "code",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["template"] == {
|
||||
"required": True,
|
||||
|
|
@ -57,6 +60,7 @@ def test_prompt_template(client: TestClient):
|
|||
"name": "template",
|
||||
"type": "prompt",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["template_format"] == {
|
||||
"required": False,
|
||||
|
|
@ -68,6 +72,7 @@ def test_prompt_template(client: TestClient):
|
|||
"name": "template_format",
|
||||
"type": "str",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["validate_template"] == {
|
||||
"required": False,
|
||||
|
|
@ -79,6 +84,7 @@ def test_prompt_template(client: TestClient):
|
|||
"name": "validate_template",
|
||||
"type": "bool",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -100,6 +106,7 @@ def test_few_shot_prompt_template(client: TestClient):
|
|||
"name": "examples",
|
||||
"type": "prompt",
|
||||
"list": True,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["example_selector"] == {
|
||||
"required": False,
|
||||
|
|
@ -110,6 +117,7 @@ def test_few_shot_prompt_template(client: TestClient):
|
|||
"name": "example_selector",
|
||||
"type": "BaseExampleSelector",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["example_prompt"] == {
|
||||
"required": True,
|
||||
|
|
@ -120,6 +128,7 @@ def test_few_shot_prompt_template(client: TestClient):
|
|||
"name": "example_prompt",
|
||||
"type": "PromptTemplate",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["suffix"] == {
|
||||
"required": True,
|
||||
|
|
@ -130,6 +139,7 @@ def test_few_shot_prompt_template(client: TestClient):
|
|||
"name": "suffix",
|
||||
"type": "prompt",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["example_separator"] == {
|
||||
"required": False,
|
||||
|
|
@ -141,6 +151,7 @@ def test_few_shot_prompt_template(client: TestClient):
|
|||
"name": "example_separator",
|
||||
"type": "str",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["prefix"] == {
|
||||
"required": False,
|
||||
|
|
@ -152,6 +163,7 @@ def test_few_shot_prompt_template(client: TestClient):
|
|||
"name": "prefix",
|
||||
"type": "prompt",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -172,6 +184,7 @@ def test_zero_shot_prompt(client: TestClient):
|
|||
"name": "prefix",
|
||||
"type": "str",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["suffix"] == {
|
||||
"required": True,
|
||||
|
|
@ -183,6 +196,7 @@ def test_zero_shot_prompt(client: TestClient):
|
|||
"name": "suffix",
|
||||
"type": "str",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
assert template["format_instructions"] == {
|
||||
"required": False,
|
||||
|
|
@ -194,4 +208,5 @@ def test_zero_shot_prompt(client: TestClient):
|
|||
"name": "format_instructions",
|
||||
"type": "str",
|
||||
"list": False,
|
||||
"advanced": True,
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue