QNA store objects
Submodules
vianops_client.models.qnastore.chart_generation module
- pydantic model V1ChartFewshotItem
Bases:
BaseModel
Show JSON schema
{ "title": "V1ChartFewshotItem", "type": "object", "properties": { "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "chart type", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "created by", "title": "Created By" }, "query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql query", "title": "Query" }, "similarity_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "similarity score", "title": "Similarity Score" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql response", "title": "Sql Query" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of template", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "type of question", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "complexity of query", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "is a suggested query", "title": "Is Suggested" } } }
- Fields:
- field chart_type: str | None = None
chart type
- field complexity: str | None = None
complexity of query
- field created_by: str | None = None
created by
- field is_suggested: bool | None = False
is a suggested query
- field query: str | None = None
golden sql query
- field question_type: str | None = None
type of question
- field similarity_score: float | None = None
similarity score
- field sql_query: str | None = None
golden sql response
- field template_name: str | None = None
name of template
- pydantic model V1ChartGen
Bases:
BaseModel
Show JSON schema
{ "title": "V1ChartGen", "type": "object", "properties": { "data": { "description": "list of data points", "title": "Data", "type": "object" }, "query": { "description": "query by user", "title": "Query", "type": "string" }, "sql": { "description": "sql response", "title": "Sql", "type": "string" }, "qna_metadata_name": { "description": "name of qna metadata", "title": "Qna Metadata Name", "type": "string" }, "fewshot": { "description": "golden sql examples given to the model", "items": { "$ref": "#/$defs/V1ChartFewshotItem" }, "title": "Fewshot", "type": "array" } }, "$defs": { "V1ChartFewshotItem": { "properties": { "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "chart type", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "created by", "title": "Created By" }, "query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql query", "title": "Query" }, "similarity_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "similarity score", "title": "Similarity Score" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql response", "title": "Sql Query" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of template", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "type of question", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "complexity of query", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "is a suggested query", "title": "Is Suggested" } }, "title": "V1ChartFewshotItem", "type": "object" } }, "required": [ "data", "query", "sql", "qna_metadata_name", "fewshot" ] }
- Fields:
- field data: dict [Required]
list of data points
- field fewshot: List[V1ChartFewshotItem] [Required]
golden sql examples given to the model
- field qna_metadata_name: str [Required]
name of qna metadata
- field query: str [Required]
query by user
- field sql: str [Required]
sql response
- pydantic model V1ChartGenResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1ChartGenResponse", "type": "object", "properties": { "qnaio_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qnaio", "title": "Qnaio Uuid" }, "Source": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source information", "title": "Source" }, "answer": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of answers", "title": "Answer" }, "data_types": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "data types", "title": "Data Types" }, "dataframe": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of dataframes", "title": "Dataframe" }, "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "chart title", "title": "Title" }, "chart": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "chart information", "title": "Chart" }, "extras": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorExtrasItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of extra items", "title": "Extras" }, "column_metadata": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "column metadata information", "title": "Column Metadata" }, "agg_dataframe": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "aggregate dataframe", "title": "Agg Dataframe" }, "agg_chart": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "aggregate chart", "title": "Agg Chart" }, "question_identifier": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "question identifier", "title": "Question Identifier" }, "sql_explanation": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "sql explain", "title": "Sql Explanation" } }, "$defs": { "V1OrchestratorExtrasItem": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the extra item", "title": "Name" }, "content": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorQuerySummary" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query summaries for this extra", "title": "Content" } }, "title": "V1OrchestratorExtrasItem", "type": "object" }, "V1OrchestratorQuerySummary": { "properties": { "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Title of the query summary", "title": "Title" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the query", "title": "Summary" } }, "title": "V1OrchestratorQuerySummary", "type": "object" } } }
- Fields:
- field Source: str | None = None
source information
- field agg_chart: dict | None = None
aggregate chart
- field agg_dataframe: List[dict] | None = None
aggregate dataframe
- field answer: List[str] | None = None
list of answers
- field chart: dict | None = None
chart information
- field column_metadata: dict | None = None
column metadata information
- field data_types: dict | None = None
data types
- field dataframe: List[dict] | None = None
list of dataframes
- field extras: List[V1OrchestratorExtrasItem] | None = None
list of extra items
- field qnaio_uuid: str | None = None
uuid of qnaio
- field question_identifier: str | None = None
question identifier
- field sql_explanation: str | None = None
sql explain
- field title: str | None = None
chart title
vianops_client.models.qnastore.jargon_identification module
- pydantic model V1JargonIdentificationRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1JargonIdentificationRequest", "type": "object", "properties": { "query": { "description": "query given by user", "title": "Query", "type": "string" }, "qna_metadata_name": { "default": null, "description": "name of metadata", "title": "Qna Metadata Name", "type": "string" }, "user": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "username of user", "title": "User" }, "source": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source of query (user information)", "title": "Source" } }, "required": [ "query" ] }
- field qna_metadata_name: str = None
name of metadata
- field query: str [Required]
query given by user
- field source: str | None = None
source of query (user information)
- field user: str | None = None
username of user
- pydantic model V1JargonIdentificationResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1JargonIdentificationResponse", "type": "object", "properties": { "jargon_identified": { "description": "final status from jargon identification logic (all | partial | null)", "title": "Jargon Identified", "type": "string" }, "identified": { "description": "keywords in the query that were matched with jargons and their associating metadata", "title": "Identified", "type": "object" }, "not_identified": { "description": "keywords that were unidentified but did not match with the jargons stored", "title": "Not Identified", "type": "object" } }, "required": [ "jargon_identified", "identified", "not_identified" ] }
- field identified: dict [Required]
keywords in the query that were matched with jargons and their associating metadata
- field jargon_identified: str [Required]
final status from jargon identification logic (all | partial | null)
- field not_identified: dict [Required]
keywords that were unidentified but did not match with the jargons stored
vianops_client.models.qnastore.jargon_lexicon module
- pydantic model V1JargonFilters
Bases:
BaseModel
Show JSON schema
{ "title": "V1JargonFilters", "type": "object", "properties": { "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of UUIDs to filter by", "title": "Uuids" }, "jargons": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of jargon terms to filter by", "title": "Jargons" }, "meanings": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of meanings to filter by", "title": "Meanings" }, "versions": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of version numbers to filter by", "title": "Versions" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses to filter by (e.g., active, archived, deleted)", "title": "Status" }, "user_groups": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of user groups to filter by", "title": "User Groups" }, "qna_metadata_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QnA metadata UUIDs to filter by", "title": "Qna Metadata Uuids" }, "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of creators to filter by (e.g., user or system names)", "title": "Created By" }, "created_ts": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of creation timestamps to filter by", "title": "Created Ts" } } }
- Config:
populate_by_name: bool = True
alias_generator: function = <function V1JargonFilters.<lambda> at 0x7f98c4e05300>
- Fields:
- field created_by: List[str] | None = None
List of creators to filter by (e.g., user or system names)
- field created_ts: List[str] | None = None
List of creation timestamps to filter by
- field jargon: List[str] | None = None (alias 'jargons')
List of jargon terms to filter by
- field meaning: List[str] | None = None (alias 'meanings')
List of meanings to filter by
- field qna_metadata_uuid: List[str] | None = None (alias 'qna_metadata_uuids')
List of QnA metadata UUIDs to filter by
- field status: List[str] | None = None
List of statuses to filter by (e.g., active, archived, deleted)
- field user_group: List[str] | None = None (alias 'user_groups')
List of user groups to filter by
- field uuid: List[str] | None = None (alias 'uuids')
List of UUIDs to filter by
- field version: List[int] | None = None (alias 'versions')
List of version numbers to filter by
- pydantic model V1JargonModel
Bases:
BaseModel
Show JSON schema
{ "title": "V1JargonModel", "type": "object", "properties": { "uuid": { "description": "Unique identifier for the jargon", "title": "Uuid", "type": "string" }, "jargon": { "description": "The keyword or term representing the jargon", "title": "Jargon", "type": "string" }, "meaning": { "description": "The meaning or definition of the jargon", "title": "Meaning", "type": "string" }, "version": { "description": "The version number of the jargon", "title": "Version", "type": "integer" }, "status": { "description": "The status of the jargon. Supported values: `active`, `archived`, `deleted`)", "title": "Status", "type": "string" }, "user_group": { "description": "The scope of the jargon", "title": "User Group", "type": "string" }, "qna_metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional UUID associated with QnA metadata", "title": "Qna Metadata Uuid" }, "created_by": { "description": "The user or system that created the jargon entry", "title": "Created By", "type": "string" }, "created_ts": { "anyOf": [ { "type": "string" }, { "type": "integer" } ], "description": "Timestamp indicating when the jargon was created", "title": "Created Ts" }, "jargon_embedding": { "description": "Vector representation (embedding) of the jargon", "items": { "type": "number" }, "title": "Jargon Embedding", "type": "array" }, "meaning_embedding": { "description": "Vector representation (embedding) of the meaning", "items": { "type": "number" }, "title": "Meaning Embedding", "type": "array" } }, "required": [ "uuid", "jargon", "meaning", "version", "status", "user_group", "created_by", "created_ts", "jargon_embedding", "meaning_embedding" ] }
- Fields:
- field created_by: str [Required]
The user or system that created the jargon entry
- field created_ts: str | int [Required]
Timestamp indicating when the jargon was created
- field jargon: str [Required]
The keyword or term representing the jargon
- field jargon_embedding: List[float] [Required]
Vector representation (embedding) of the jargon
- field meaning: str [Required]
The meaning or definition of the jargon
- field meaning_embedding: List[float] [Required]
Vector representation (embedding) of the meaning
- field qna_metadata_uuid: str | None = None
Optional UUID associated with QnA metadata
- field status: str [Required]
The status of the jargon. Supported values: active, archived, deleted)
- field user_group: str [Required]
The scope of the jargon
- field uuid: str [Required]
Unique identifier for the jargon
- field version: int [Required]
The version number of the jargon
- pydantic model V1JargonModelPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1JargonModelPage", "type": "object", "properties": { "items": { "default": "A list of jargon items returned from the paginated search", "items": { "$ref": "#/$defs/V1JargonModel" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1JargonModel": { "properties": { "uuid": { "description": "Unique identifier for the jargon", "title": "Uuid", "type": "string" }, "jargon": { "description": "The keyword or term representing the jargon", "title": "Jargon", "type": "string" }, "meaning": { "description": "The meaning or definition of the jargon", "title": "Meaning", "type": "string" }, "version": { "description": "The version number of the jargon", "title": "Version", "type": "integer" }, "status": { "description": "The status of the jargon. Supported values: `active`, `archived`, `deleted`)", "title": "Status", "type": "string" }, "user_group": { "description": "The scope of the jargon", "title": "User Group", "type": "string" }, "qna_metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional UUID associated with QnA metadata", "title": "Qna Metadata Uuid" }, "created_by": { "description": "The user or system that created the jargon entry", "title": "Created By", "type": "string" }, "created_ts": { "anyOf": [ { "type": "string" }, { "type": "integer" } ], "description": "Timestamp indicating when the jargon was created", "title": "Created Ts" }, "jargon_embedding": { "description": "Vector representation (embedding) of the jargon", "items": { "type": "number" }, "title": "Jargon Embedding", "type": "array" }, "meaning_embedding": { "description": "Vector representation (embedding) of the meaning", "items": { "type": "number" }, "title": "Meaning Embedding", "type": "array" } }, "required": [ "uuid", "jargon", "meaning", "version", "status", "user_group", "created_by", "created_ts", "jargon_embedding", "meaning_embedding" ], "title": "V1JargonModel", "type": "object" } } }
- field items: List[V1JargonModel] = 'A list of jargon items returned from the paginated search'
- pydantic model V1JargonModelResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1JargonModelResponseList", "type": "array", "$defs": { "V1JargonModel": { "properties": { "uuid": { "description": "Unique identifier for the jargon", "title": "Uuid", "type": "string" }, "jargon": { "description": "The keyword or term representing the jargon", "title": "Jargon", "type": "string" }, "meaning": { "description": "The meaning or definition of the jargon", "title": "Meaning", "type": "string" }, "version": { "description": "The version number of the jargon", "title": "Version", "type": "integer" }, "status": { "description": "The status of the jargon. Supported values: `active`, `archived`, `deleted`)", "title": "Status", "type": "string" }, "user_group": { "description": "The scope of the jargon", "title": "User Group", "type": "string" }, "qna_metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional UUID associated with QnA metadata", "title": "Qna Metadata Uuid" }, "created_by": { "description": "The user or system that created the jargon entry", "title": "Created By", "type": "string" }, "created_ts": { "anyOf": [ { "type": "string" }, { "type": "integer" } ], "description": "Timestamp indicating when the jargon was created", "title": "Created Ts" }, "jargon_embedding": { "description": "Vector representation (embedding) of the jargon", "items": { "type": "number" }, "title": "Jargon Embedding", "type": "array" }, "meaning_embedding": { "description": "Vector representation (embedding) of the meaning", "items": { "type": "number" }, "title": "Meaning Embedding", "type": "array" } }, "required": [ "uuid", "jargon", "meaning", "version", "status", "user_group", "created_by", "created_ts", "jargon_embedding", "meaning_embedding" ], "title": "V1JargonModel", "type": "object" } }, "items": { "$ref": "#/$defs/V1JargonModel" } }
- field root: List[V1JargonModel] [Required]
- pydantic model V1JargonRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1JargonRequest", "type": "object", "properties": { "jargons": { "additionalProperties": { "type": "string" }, "description": "Dictionary where the key is the jargon term and the value is its meaning", "title": "Jargons", "type": "object" }, "qna_metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional UUID associated with QnA metadata, if applicable", "title": "Qna Metadata Uuid" }, "user_group": { "default": "*", "description": "The scope or context in which the jargon is relevant.", "title": "User Group", "type": "string" } }, "required": [ "jargons" ] }
- Fields:
- Validators:
- field jargons: Dict[str, str] [Required]
Dictionary where the key is the jargon term and the value is its meaning
- Validated by:
- field qna_metadata_uuid: str | None = None
Optional UUID associated with QnA metadata, if applicable
- field user_group: str = '*'
The scope or context in which the jargon is relevant.
- Validated by:
- validator set_default_user_group » user_group
- pydantic model V1JargonRequestList
Bases:
RootModel
Show JSON schema
{ "title": "V1JargonRequestList", "type": "array", "$defs": { "V1JargonRequest": { "properties": { "jargons": { "additionalProperties": { "type": "string" }, "description": "Dictionary where the key is the jargon term and the value is its meaning", "title": "Jargons", "type": "object" }, "qna_metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional UUID associated with QnA metadata, if applicable", "title": "Qna Metadata Uuid" }, "user_group": { "default": "*", "description": "The scope or context in which the jargon is relevant.", "title": "User Group", "type": "string" } }, "required": [ "jargons" ], "title": "V1JargonRequest", "type": "object" } }, "items": { "$ref": "#/$defs/V1JargonRequest" } }
- Fields:
- Validators:
- field root: List[V1JargonRequest] [Required]
- Validated by:
- pydantic model V1JargonSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1JargonSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "anyOf": [ { "$ref": "#/$defs/V1JargonFilters" }, { "type": "null" } ], "description": "Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved." } }, "$defs": { "V1JargonFilters": { "properties": { "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of UUIDs to filter by", "title": "Uuids" }, "jargons": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of jargon terms to filter by", "title": "Jargons" }, "meanings": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of meanings to filter by", "title": "Meanings" }, "versions": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of version numbers to filter by", "title": "Versions" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses to filter by (e.g., active, archived, deleted)", "title": "Status" }, "user_groups": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of user groups to filter by", "title": "User Groups" }, "qna_metadata_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QnA metadata UUIDs to filter by", "title": "Qna Metadata Uuids" }, "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of creators to filter by (e.g., user or system names)", "title": "Created By" }, "created_ts": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of creation timestamps to filter by", "title": "Created Ts" } }, "title": "V1JargonFilters", "type": "object" }, "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" } } }
- field filters: V1JargonFilters | None = <class 'vianops_client.models.qnastore.jargon_lexicon.V1JargonFilters'>
Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved.
- pydantic model V1JargonUpdate
Bases:
BaseModel
Show JSON schema
{ "title": "V1JargonUpdate", "type": "object", "properties": { "jargon": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The updated jargon value", "title": "Jargon" }, "meaning": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The updated meaning of the jargon", "title": "Meaning" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The updated status of the jargon (e.g., active, archived, deleted)", "title": "Status" }, "user_group": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The updated user group associated with the jargon", "title": "User Group" }, "qna_metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The updated UUID associated with QnA metadata, if applicable", "title": "Qna Metadata Uuid" }, "filters": { "anyOf": [ { "$ref": "#/$defs/V1JargonFilters" }, { "type": "null" } ], "default": null, "description": "Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved." } }, "$defs": { "V1JargonFilters": { "properties": { "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of UUIDs to filter by", "title": "Uuids" }, "jargons": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of jargon terms to filter by", "title": "Jargons" }, "meanings": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of meanings to filter by", "title": "Meanings" }, "versions": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of version numbers to filter by", "title": "Versions" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses to filter by (e.g., active, archived, deleted)", "title": "Status" }, "user_groups": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of user groups to filter by", "title": "User Groups" }, "qna_metadata_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QnA metadata UUIDs to filter by", "title": "Qna Metadata Uuids" }, "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of creators to filter by (e.g., user or system names)", "title": "Created By" }, "created_ts": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of creation timestamps to filter by", "title": "Created Ts" } }, "title": "V1JargonFilters", "type": "object" } } }
- Fields:
- Validators:
check_at_least_one_field
»all fields
- field filters: V1JargonFilters | None = None
Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved.
- Validated by:
- field jargon: str | None = None
The updated jargon value
- Validated by:
- field meaning: str | None = None
The updated meaning of the jargon
- Validated by:
- field qna_metadata_uuid: str | None = None
The updated UUID associated with QnA metadata, if applicable
- Validated by:
- field status: str | None = None
The updated status of the jargon (e.g., active, archived, deleted)
- Validated by:
- field user_group: str | None = None
The updated user group associated with the jargon
- Validated by:
- validator check_at_least_one_field » all fields
vianops_client.models.qnastore.llm_registry module
vianops_client.models.qnastore.qna_conversation module
- pydantic model V1BaseQNAConversation
Bases:
BaseModel
Show JSON schema
{ "title": "V1BaseQNAConversation", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation description", "title": "Description" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_value", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna conversation", "title": "Status" }, "user_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User name associated with the QNA Conversation", "title": "User Name" }, "context_window": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Context window for the current conversation", "title": "Context Window" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to mark QNA Conversation as report", "title": "Is Report" } } }
- Fields:
- field context_window: int | None = None
Context window for the current conversation
- field description: str | None = None
qna conversation description
- field feedback_comment: str | None = None
qna conversation feedback_comment
- field feedback_value: bool | None = None
qna conversation feedback_value
- field is_favorite: bool | None = None
flag to make favorite QNA Conversation
- field is_pinned: bool | None = None
flag to pin QNA Conversation
- field is_report: bool | None = None
flag to mark QNA Conversation as report
- field name: str | None = None
qna conversation name
- field status: str | None = 'CREATED'
Status of the qna conversation
- field user_name: str | None = None
User name associated with the QNA Conversation
- field uuid: str | None = None
uuid
- pydantic model V1QNAConversationFilters
Bases:
V1FiltersCommon
Show JSON schema
{ "title": "V1QNAConversationFilters", "type": "object", "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna conversation uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna conversation names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "context_windows": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna conversation context window", "title": "Context Windows" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of feedback_value for this operation.", "title": "Feedback Value" }, "feedback_comments": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of feedback_comment for this operation.", "title": "Feedback Comments" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" }, "user_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List User name associated with the QNA Conversation", "title": "User Names" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to mark QNA Conversation as report", "title": "Is Report" } }, "example": { "names": [ "Example qna Conversation" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
alias_generator: function = <function V1QNAConversationFilters.<lambda> at 0x7f98c4d7b560>
json_schema_extra: dict = {‘example’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example qna Conversation’]}}
- Fields:
- field context_window: List[int] | None = None (alias 'context_windows')
List qna conversation context window
- field description: List[str] | None = None (alias 'descriptions')
List of descriptions for this operation.
- field feedback_comment: List[str] | None = None (alias 'feedback_comments')
List of feedback_comment for this operation.
- field feedback_value: bool | None = None
List of feedback_value for this operation.
- field is_favorite: bool | None = None
Flag to make favorite QNA Conversation
- field is_pinned: bool | None = None
Flag to pin QNA Conversation
- field is_report: bool | None = None
Flag to mark QNA Conversation as report
- field name: List[str] | None = None (alias 'names')
List of qna conversation names for this operation.
- field status: List[str] | None = None (alias 'statuses')
List of status for this operation.
- field user_name: List[str] | None = None (alias 'user_names')
List User name associated with the QNA Conversation
- field uuid: List[str] | None = None (alias 'uuids')
List of qna conversation uuids for this operation.
- pydantic model V1QNAConversationList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAConversationList", "type": "array", "$defs": { "V1BaseQNAConversation": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation description", "title": "Description" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_value", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna conversation", "title": "Status" }, "user_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User name associated with the QNA Conversation", "title": "User Name" }, "context_window": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Context window for the current conversation", "title": "Context Window" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to mark QNA Conversation as report", "title": "Is Report" } }, "title": "V1BaseQNAConversation", "type": "object" } }, "items": { "$ref": "#/$defs/V1BaseQNAConversation" } }
- field root: List[V1BaseQNAConversation] [Required]
- pydantic model V1QNAConversationPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1QNAConversationPage", "type": "object", "properties": { "items": { "default": [], "description": "Job Types returned by search in page.", "items": { "$ref": "#/$defs/V1QNAConversationResponse" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1QNAConversationResponse": { "properties": { "uuid": { "description": "uuid", "title": "Uuid", "type": "string" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation description", "title": "Description" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_value", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna conversation", "title": "Status" }, "user_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User name associated with the QNA Conversation", "title": "User Name" }, "context_window": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Context window for the current conversation", "title": "Context Window" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to mark QNA Conversation as report", "title": "Is Report" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Conversation", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Conversation", "title": "Modified By", "type": "string" }, "message_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "total messages in the current conversation", "title": "Message Count" }, "favorites_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "total favorite messages in the current conversation", "title": "Favorites Count" }, "last_message_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "last message time in the converastion", "title": "Last Message Ts" }, "last_message_sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of last message sources", "title": "Last Message Sources" } }, "required": [ "uuid", "created_ts", "modified_ts", "created_by", "modified_by" ], "title": "V1QNAConversationResponse", "type": "object" } } }
- field items: List[V1QNAConversationResponse] = []
Job Types returned by search in page.
- pydantic model V1QNAConversationResponse
Bases:
V1BaseQNAConversation
Show JSON schema
{ "title": "V1QNAConversationResponse", "type": "object", "properties": { "uuid": { "description": "uuid", "title": "Uuid", "type": "string" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation description", "title": "Description" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_value", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna conversation", "title": "Status" }, "user_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User name associated with the QNA Conversation", "title": "User Name" }, "context_window": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Context window for the current conversation", "title": "Context Window" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to mark QNA Conversation as report", "title": "Is Report" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Conversation", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Conversation", "title": "Modified By", "type": "string" }, "message_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "total messages in the current conversation", "title": "Message Count" }, "favorites_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "total favorite messages in the current conversation", "title": "Favorites Count" }, "last_message_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "last message time in the converastion", "title": "Last Message Ts" }, "last_message_sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of last message sources", "title": "Last Message Sources" } }, "required": [ "uuid", "created_ts", "modified_ts", "created_by", "modified_by" ] }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field context_window: int | None = None
Context window for the current conversation
- field created_by: str [Required]
User that created the QNA Conversation
- field created_ts: datetime [Required]
Unix time in milliseconds generated at creation time.
- field favorites_count: int | None = None
total favorite messages in the current conversation
- field last_message_sources: List[str] | None = None
list of last message sources
- field last_message_ts: datetime | None = None
last message time in the converastion
- field message_count: int | None = None
total messages in the current conversation
- field modified_by: str [Required]
User who modified the QNA Conversation
- field modified_ts: datetime [Required]
Unix time in milliseconds generated at last modification time.
- field user_name: str | None = None
User name associated with the QNA Conversation
- field uuid: str [Required]
uuid
- pydantic model V1QNAConversationResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAConversationResponseList", "type": "array", "$defs": { "V1QNAConversationResponse": { "properties": { "uuid": { "description": "uuid", "title": "Uuid", "type": "string" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation description", "title": "Description" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_value", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna conversation", "title": "Status" }, "user_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User name associated with the QNA Conversation", "title": "User Name" }, "context_window": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Context window for the current conversation", "title": "Context Window" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to mark QNA Conversation as report", "title": "Is Report" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Conversation", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Conversation", "title": "Modified By", "type": "string" }, "message_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "total messages in the current conversation", "title": "Message Count" }, "favorites_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "total favorite messages in the current conversation", "title": "Favorites Count" }, "last_message_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "last message time in the converastion", "title": "Last Message Ts" }, "last_message_sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of last message sources", "title": "Last Message Sources" } }, "required": [ "uuid", "created_ts", "modified_ts", "created_by", "modified_by" ], "title": "V1QNAConversationResponse", "type": "object" } }, "items": { "$ref": "#/$defs/V1QNAConversationResponse" } }
- field root: List[V1QNAConversationResponse] [Required]
- pydantic model V1QNAConversationSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1QNAConversationSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "$ref": "#/$defs/V1QNAConversationFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" }, "V1QNAConversationFilters": { "example": { "names": [ "Example qna Conversation" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna conversation uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna conversation names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "context_windows": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna conversation context window", "title": "Context Windows" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of feedback_value for this operation.", "title": "Feedback Value" }, "feedback_comments": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of feedback_comment for this operation.", "title": "Feedback Comments" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" }, "user_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List User name associated with the QNA Conversation", "title": "User Names" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to mark QNA Conversation as report", "title": "Is Report" } }, "title": "V1QNAConversationFilters", "type": "object" } }, "example": { "filters": { "names": [ "Example qna conversation metrics" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "order": [ { "direction": "DESC", "field": "name" } ], "page": 1, "page_size": 100, "search": "vianai" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘page’: 1, ‘page_size’: 100, ‘order’: [{‘field’: ‘name’, ‘direction’: ‘DESC’}], ‘search’: ‘vianai’, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example qna conversation metrics’]}}}
- Fields:
- field filters: V1QNAConversationFilters [Required]
Specifies different condition(s) for filtering the results.
- pydantic model V1QNAConversationUpdates
Bases:
V1BaseQNAConversation
Show JSON schema
{ "title": "V1QNAConversationUpdates", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation description", "title": "Description" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_value", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna conversation feedback_comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna conversation", "title": "Status" }, "user_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User name associated with the QNA Conversation", "title": "User Name" }, "context_window": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "qna conversation context window", "title": "Context Window" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to mark QNA Conversation as report", "title": "Is Report" }, "filters": { "$ref": "#/$defs/V1QNAConversationFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1QNAConversationFilters": { "example": { "names": [ "Example qna Conversation" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna conversation uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna conversation names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "context_windows": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna conversation context window", "title": "Context Windows" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of feedback_value for this operation.", "title": "Feedback Value" }, "feedback_comments": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of feedback_comment for this operation.", "title": "Feedback Comments" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" }, "user_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List User name associated with the QNA Conversation", "title": "User Names" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to pin QNA Conversation", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to make favorite QNA Conversation", "title": "Is Favorite" }, "is_report": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to mark QNA Conversation as report", "title": "Is Report" } }, "title": "V1QNAConversationFilters", "type": "object" } }, "example": { "context_window": 1, "description": "Updated qna conversation description", "filters": { "names": [ "Example qna conversation" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "name": "Updated qna conversation name" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘name’: ‘Updated qna conversation name’, ‘description’: ‘Updated qna conversation description’, ‘context_window’: 1, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example qna conversation’]}}}
- Fields:
- field context_window: int | None = None
qna conversation context window
- field description: str | None = None
qna conversation description
- field filters: V1QNAConversationFilters [Required]
Specifies different condition(s) for filtering the results.
- field name: str | None = None
qna conversation name
vianops_client.models.qnastore.qna_io module
- pydantic model V1QnaIo
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaIo", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of metadata (foreign key)", "title": "Metadata Uuid" }, "user_input": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "user input of qna io", "title": "User Input" }, "query_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "query type of qna io", "title": "Query Type" }, "input_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding ids of qna io", "title": "Input Embedding Ids" }, "output_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding ids of qna io", "title": "Output Embedding Ids" }, "context_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "context embedding ids of qna io", "title": "Context Embedding Ids" }, "few_shot_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "few shot ids of qna io", "title": "Few Shot Ids" }, "input_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embeddings", "title": "Input Embedding" }, "raw_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "raw output embeddings", "title": "Raw Output Embedding" }, "final_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final output embeddings", "title": "Final Output Embedding" }, "input_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding cluster ids", "title": "Input Embedding Cluster Id" }, "raw_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding cluster ids", "title": "Raw Output Embedding Cluster Id" }, "final_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final embedding cluster ids", "title": "Final Output Embedding Cluster Id" }, "tx_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "tx id", "title": "Tx Id" }, "tx_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Tx Time" }, "llm_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "llm prompt of qna io", "title": "Llm Prompt" }, "raw_output": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "raw output of qna io", "title": "Raw Output" }, "final_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "final output of qna io", "title": "Final Output" }, "anti_hallucination_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "anti-hallucination output of qna io's raw output", "title": "Anti Hallucination Output" }, "decomposed_queries": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "decomposed queries of qna io", "title": "Decomposed Queries" }, "exceptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "exceptions of qna io", "title": "Exceptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of sources", "title": "Sources" }, "use_case": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "use case", "title": "Use Case" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "feedback value of qna io", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "feedback comment of qna io", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "active", "description": "status of qna io", "title": "Status" }, "jobs": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "A mapping for job types to job ids for jobs associated to io entry", "title": "Jobs" }, "derived_features": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional features needed for LLM monitoring", "title": "Derived Features" }, "service": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "LLM monitoring service. Values include: \n `summarization`, \n `chart`, \n `agg_chart`,\n `sanitization`,\n `summary_generation`, \n `title_generation_prompt`,\n `text2sql`,\n `agg_table`,\n `column_metadata`,\n `prompt generator`\n .", "title": "Service" }, "transaction_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Transaction uuid to identify entries added per request.", "title": "Transaction Uuid" }, "high_confidence_status": { "anyOf": [ { "enum": [ "requested", "approved", "declined" ], "type": "string" }, { "type": "null" } ], "default": null, "description": "stores if an io is high confidence or not, possible values ('requested', 'approved', 'declined')", "title": "High Confidence Status" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "comment made to while changing confidence of an io", "title": "Confidence Change Comment" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "vianai", "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Qna thread uuid to identify entries added per request.", "title": "Qna Thread Uuid" }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Process state of the qna io", "title": "Process State" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Uuid of current qna conversation", "title": "Qna Conversation Uuid" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to indicate if the query is a followup query", "title": "Flag Followup" }, "flag_fuzzy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Flag to indicate if fuzzy match is enabled", "title": "Flag Fuzzy" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA IO", "title": "Is Favorite" } } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field anti_hallucination_output: dict | None = None
anti-hallucination output of qna io’s raw output
- field confidence_change_comment: str | None = None
comment made to while changing confidence of an io
- field context_embedding_ids: List[str] | None = None
context embedding ids of qna io
- field created_by: str | None = 'vianai'
User that created the qna io
- field created_ts: datetime | None = None
Unix time in milliseconds generated at creation time.
- field decomposed_queries: List[str] | None = None
decomposed queries of qna io
- field derived_features: dict | None = None
Additional features needed for LLM monitoring
- field exceptions: List[str] | None = None
exceptions of qna io
- field feedback_comment: str | None = None
feedback comment of qna io
- field feedback_value: bool | None = None
feedback value of qna io
- field few_shot_ids: List[str] | None = None
few shot ids of qna io
- field final_output: dict | None = None
final output of qna io
- field final_output_embedding: List[float] | None = None
final output embeddings
- field final_output_embedding_cluster_id: List[int] | None = None
final embedding cluster ids
- field flag_followup: bool | None = None
Flag to indicate if the query is a followup query
- field flag_fuzzy: bool | None = True
Flag to indicate if fuzzy match is enabled
- field high_confidence_status: Literal['requested', 'approved', 'declined'] | None = None
stores if an io is high confidence or not, possible values (‘requested’, ‘approved’, ‘declined’)
- field input_embedding: List[float] | None = None
input embeddings
- field input_embedding_cluster_id: List[int] | None = None
input embedding cluster ids
- field input_embedding_ids: List[str] | None = None
input embedding ids of qna io
- field is_favorite: bool | None = None
flag to make favorite QNA IO
- field is_pinned: bool | None = None
flag to pin QNA IO
- field jobs: dict | None = None
A mapping for job types to job ids for jobs associated to io entry
- field llm_prompt: str | None = None
llm prompt of qna io
- field metadata_uuid: str | None = None
uuid of metadata (foreign key)
- field modified_by: str | None = None
User that modified the qna io
- field modified_ts: datetime | None = None
Unix time in milliseconds generated at last modification time.
- field output_embedding_ids: List[str] | None = None
output embedding ids of qna io
- field process_state: dict | None = None
Process state of the qna io
- field qna_conversation_uuid: str | None = None
Uuid of current qna conversation
- field qna_thread_uuid: str | None = None
Qna thread uuid to identify entries added per request.
- field query_type: str | None = None
query type of qna io
- field raw_output: str | None = None
raw output of qna io
- field raw_output_embedding: List[float] | None = None
raw output embeddings
- field raw_output_embedding_cluster_id: List[int] | None = None
output embedding cluster ids
- field service: str | None = None
LLM monitoring service. Values include: summarization, chart, agg_chart, sanitization, summary_generation, title_generation_prompt, text2sql, agg_table, column_metadata, prompt generator .
- field sources: List[str] | None = None
list of sources
- field status: str | None = 'active'
status of qna io
- field transaction_uuid: str | None = None
Transaction uuid to identify entries added per request.
- field tx_id: str | None = None
tx id
- field tx_time: datetime | None = None
Unix time in milliseconds generated at last modification time.
- field use_case: str | None = None
use case
- field user_input: str | None = None
user input of qna io
- field uuid: str | None = None
uuid of operation
- pydantic model V1QnaIoConfidence
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaIoConfidence", "type": "object", "properties": { "uuid": { "description": "uuid of qna_io row", "title": "Uuid", "type": "string" }, "confidence_change_comment": { "default": "N/A", "description": "Comment regarding confidence change (promotion).", "title": "Confidence Change Comment", "type": "string" } }, "required": [ "uuid" ] }
- field confidence_change_comment: str = 'N/A'
Comment regarding confidence change (promotion).
- field uuid: str [Required]
uuid of qna_io row
- pydantic model V1QnaIoFeedback
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaIoFeedback", "type": "object", "properties": { "uuid": { "description": "uuid of qna_io row", "title": "Uuid", "type": "string" }, "feedback_value": { "description": "Feedback value. Posive feedback store as `true`, and negative feedback stored as 'false'.", "title": "Feedback Value", "type": "boolean" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Feedback comment.", "title": "Feedback Comment" } }, "required": [ "uuid", "feedback_value" ] }
- field feedback_comment: str | None = None
Feedback comment.
- field feedback_value: bool [Required]
Feedback value. Posive feedback store as true, and negative feedback stored as ‘false’.
- field uuid: str [Required]
uuid of qna_io row
- pydantic model V1QnaIoFilters
Bases:
V1Filters
Show JSON schema
{ "title": "V1QnaIoFilters", "type": "object", "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of created_by for this operation.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of uuids for this operation", "title": "Uuids" }, "name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of names for this operation.", "title": "Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses for this operation.", "title": "Status" }, "metadata_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata_uuid for this operation", "title": "Metadata Uuids" }, "services": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of services.", "title": "Services" }, "transaction_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of transaction ids.", "title": "Transaction Uuids" }, "qna_thread_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of transaction ids.", "title": "Qna Thread Uuids" }, "source": { "anyOf": [ { "items": { "items": { "type": "string" }, "type": "array" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "source for qnaio", "title": "Source" }, "high_confidence_statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "source for qnaio", "title": "High Confidence Statuses" }, "qna_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of conversation ids.", "title": "Qna Conversation Uuids" }, "query_types": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query_types", "title": "Query Types" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag_followup", "title": "Flag Followup" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag to make favorite QNA IO", "title": "Is Favorite" }, "favorites_toggle": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to perform favorites toggle functionality", "title": "Favorites Toggle" } } }
- Config:
populate_by_name: bool = True
alias_generator: function = <function V1QnaIoFilters.<lambda> at 0x7f98c4d7a980>
- Fields:
- field created_by: List[str] | None = None
List of created_by for this operation.
- field favorites_toggle: bool | None = None
Flag to perform favorites toggle functionality
- field flag_followup: bool | None = None
List of flag_followup
- field high_confidence_status: List[str] | None = None (alias 'high_confidence_statuses')
source for qnaio
- field is_favorite: bool | None = None
List of flag to make favorite QNA IO
- field is_pinned: bool | None = None
List of flag to pin QNA IO
- field metadata_uuid: List[str] | None = None (alias 'metadata_uuids')
List of metadata_uuid for this operation
- field qna_conversation_uuid: List[str] | None = None (alias 'qna_conversation_uuids')
List of conversation ids.
- field qna_thread_uuid: List[str] | None = None (alias 'qna_thread_uuids')
List of transaction ids.
- field query_type: List[str] | None = None (alias 'query_types')
List of query_types
- field service: List[str] | None = None (alias 'services')
List of services.
- field source: List[List[str]] | None = None
source for qnaio
- field transaction_uuid: List[str] | None = None (alias 'transaction_uuids')
List of transaction ids.
- field uuid: List[str] | None = None (alias 'uuids')
List of uuids for this operation
- pydantic model V1QnaIoList
Bases:
RootModel
Show JSON schema
{ "title": "V1QnaIoList", "type": "array", "$defs": { "V1QnaIo": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of metadata (foreign key)", "title": "Metadata Uuid" }, "user_input": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "user input of qna io", "title": "User Input" }, "query_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "query type of qna io", "title": "Query Type" }, "input_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding ids of qna io", "title": "Input Embedding Ids" }, "output_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding ids of qna io", "title": "Output Embedding Ids" }, "context_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "context embedding ids of qna io", "title": "Context Embedding Ids" }, "few_shot_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "few shot ids of qna io", "title": "Few Shot Ids" }, "input_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embeddings", "title": "Input Embedding" }, "raw_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "raw output embeddings", "title": "Raw Output Embedding" }, "final_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final output embeddings", "title": "Final Output Embedding" }, "input_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding cluster ids", "title": "Input Embedding Cluster Id" }, "raw_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding cluster ids", "title": "Raw Output Embedding Cluster Id" }, "final_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final embedding cluster ids", "title": "Final Output Embedding Cluster Id" }, "tx_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "tx id", "title": "Tx Id" }, "tx_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Tx Time" }, "llm_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "llm prompt of qna io", "title": "Llm Prompt" }, "raw_output": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "raw output of qna io", "title": "Raw Output" }, "final_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "final output of qna io", "title": "Final Output" }, "anti_hallucination_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "anti-hallucination output of qna io's raw output", "title": "Anti Hallucination Output" }, "decomposed_queries": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "decomposed queries of qna io", "title": "Decomposed Queries" }, "exceptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "exceptions of qna io", "title": "Exceptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of sources", "title": "Sources" }, "use_case": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "use case", "title": "Use Case" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "feedback value of qna io", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "feedback comment of qna io", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "active", "description": "status of qna io", "title": "Status" }, "jobs": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "A mapping for job types to job ids for jobs associated to io entry", "title": "Jobs" }, "derived_features": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional features needed for LLM monitoring", "title": "Derived Features" }, "service": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "LLM monitoring service. Values include: \n `summarization`, \n `chart`, \n `agg_chart`,\n `sanitization`,\n `summary_generation`, \n `title_generation_prompt`,\n `text2sql`,\n `agg_table`,\n `column_metadata`,\n `prompt generator`\n .", "title": "Service" }, "transaction_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Transaction uuid to identify entries added per request.", "title": "Transaction Uuid" }, "high_confidence_status": { "anyOf": [ { "enum": [ "requested", "approved", "declined" ], "type": "string" }, { "type": "null" } ], "default": null, "description": "stores if an io is high confidence or not, possible values ('requested', 'approved', 'declined')", "title": "High Confidence Status" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "comment made to while changing confidence of an io", "title": "Confidence Change Comment" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "vianai", "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Qna thread uuid to identify entries added per request.", "title": "Qna Thread Uuid" }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Process state of the qna io", "title": "Process State" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Uuid of current qna conversation", "title": "Qna Conversation Uuid" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to indicate if the query is a followup query", "title": "Flag Followup" }, "flag_fuzzy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Flag to indicate if fuzzy match is enabled", "title": "Flag Fuzzy" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA IO", "title": "Is Favorite" } }, "title": "V1QnaIo", "type": "object" } }, "items": { "$ref": "#/$defs/V1QnaIo" } }
- pydantic model V1QnaIoModelPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1QnaIoModelPage", "type": "object", "properties": { "items": { "default": [], "description": "Job Types returned by search in page.", "items": { "$ref": "#/$defs/V1QnaIoResponse" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1QnaIoResponse": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of metadata (foreign key)", "title": "Metadata Uuid" }, "user_input": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "user input of qna io", "title": "User Input" }, "query_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "query type of qna io", "title": "Query Type" }, "input_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding ids of qna io", "title": "Input Embedding Ids" }, "output_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding ids of qna io", "title": "Output Embedding Ids" }, "context_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "context embedding ids of qna io", "title": "Context Embedding Ids" }, "few_shot_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "few shot ids of qna io", "title": "Few Shot Ids" }, "input_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embeddings", "title": "Input Embedding" }, "raw_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "raw output embeddings", "title": "Raw Output Embedding" }, "final_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final output embeddings", "title": "Final Output Embedding" }, "input_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding cluster ids", "title": "Input Embedding Cluster Id" }, "raw_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding cluster ids", "title": "Raw Output Embedding Cluster Id" }, "final_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final embedding cluster ids", "title": "Final Output Embedding Cluster Id" }, "tx_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "tx id", "title": "Tx Id" }, "tx_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Tx Time" }, "llm_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "llm prompt of qna io", "title": "Llm Prompt" }, "raw_output": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "raw output of qna io", "title": "Raw Output" }, "final_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "final output of qna io", "title": "Final Output" }, "anti_hallucination_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "anti-hallucination output of qna io's raw output", "title": "Anti Hallucination Output" }, "decomposed_queries": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "decomposed queries of qna io", "title": "Decomposed Queries" }, "exceptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "exceptions of qna io", "title": "Exceptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of sources", "title": "Sources" }, "use_case": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "use case", "title": "Use Case" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "feedback value of qna io", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "feedback comment of qna io", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "active", "description": "status of qna io", "title": "Status" }, "jobs": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "A mapping for job types to job ids for jobs associated to io entry", "title": "Jobs" }, "derived_features": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional features needed for LLM monitoring", "title": "Derived Features" }, "service": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "LLM monitoring service. Values include: \n `summarization`, \n `chart`, \n `agg_chart`,\n `sanitization`,\n `summary_generation`, \n `title_generation_prompt`,\n `text2sql`,\n `agg_table`,\n `column_metadata`,\n `prompt generator`\n .", "title": "Service" }, "transaction_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Transaction uuid to identify entries added per request.", "title": "Transaction Uuid" }, "high_confidence_status": { "anyOf": [ { "enum": [ "requested", "approved", "declined" ], "type": "string" }, { "type": "null" } ], "default": null, "description": "stores if an io is high confidence or not, possible values ('requested', 'approved', 'declined')", "title": "High Confidence Status" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "comment made to while changing confidence of an io", "title": "Confidence Change Comment" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Qna thread uuid to identify entries added per request.", "title": "Qna Thread Uuid" }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Process state of the qna io", "title": "Process State" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Uuid of current qna conversation", "title": "Qna Conversation Uuid" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to indicate if the query is a followup query", "title": "Flag Followup" }, "flag_fuzzy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Flag to indicate if fuzzy match is enabled", "title": "Flag Fuzzy" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA IO", "title": "Is Favorite" } }, "title": "V1QnaIoResponse", "type": "object" } } }
- field items: List[V1QnaIoResponse] = []
Job Types returned by search in page.
- pydantic model V1QnaIoRagOutput
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaIoRagOutput", "type": "object", "properties": { "result": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Result" }, "additional_docs": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Additional Docs" }, "no_docs_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "No Docs Message" }, "docs_input": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Docs Input" }, "qnaio_uuid": { "title": "Qnaio Uuid", "type": "string" }, "success": { "default": true, "title": "Success", "type": "boolean" }, "process_state": { "default": {}, "title": "Process State", "type": "object" }, "request_id": { "default": null, "title": "Request Id", "type": "string" }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Error" }, "metadata": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Metadata" } }, "required": [ "qnaio_uuid" ] }
- Fields:
- field additional_docs: List[dict] | None = None
- field docs_input: List[str] | None = None
- field error: str | None = None
- field metadata: List[dict] | None = None
- field no_docs_message: str | None = None
- field process_state: dict = {}
- field qnaio_uuid: str [Required]
- field request_id: str = None
- field result: List[dict] | None = None
- field success: bool = True
- pydantic model V1QnaIoResponse
Bases:
V1QnaIo
Show JSON schema
{ "title": "V1QnaIoResponse", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of metadata (foreign key)", "title": "Metadata Uuid" }, "user_input": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "user input of qna io", "title": "User Input" }, "query_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "query type of qna io", "title": "Query Type" }, "input_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding ids of qna io", "title": "Input Embedding Ids" }, "output_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding ids of qna io", "title": "Output Embedding Ids" }, "context_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "context embedding ids of qna io", "title": "Context Embedding Ids" }, "few_shot_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "few shot ids of qna io", "title": "Few Shot Ids" }, "input_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embeddings", "title": "Input Embedding" }, "raw_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "raw output embeddings", "title": "Raw Output Embedding" }, "final_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final output embeddings", "title": "Final Output Embedding" }, "input_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding cluster ids", "title": "Input Embedding Cluster Id" }, "raw_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding cluster ids", "title": "Raw Output Embedding Cluster Id" }, "final_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final embedding cluster ids", "title": "Final Output Embedding Cluster Id" }, "tx_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "tx id", "title": "Tx Id" }, "tx_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Tx Time" }, "llm_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "llm prompt of qna io", "title": "Llm Prompt" }, "raw_output": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "raw output of qna io", "title": "Raw Output" }, "final_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "final output of qna io", "title": "Final Output" }, "anti_hallucination_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "anti-hallucination output of qna io's raw output", "title": "Anti Hallucination Output" }, "decomposed_queries": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "decomposed queries of qna io", "title": "Decomposed Queries" }, "exceptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "exceptions of qna io", "title": "Exceptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of sources", "title": "Sources" }, "use_case": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "use case", "title": "Use Case" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "feedback value of qna io", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "feedback comment of qna io", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "active", "description": "status of qna io", "title": "Status" }, "jobs": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "A mapping for job types to job ids for jobs associated to io entry", "title": "Jobs" }, "derived_features": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional features needed for LLM monitoring", "title": "Derived Features" }, "service": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "LLM monitoring service. Values include: \n `summarization`, \n `chart`, \n `agg_chart`,\n `sanitization`,\n `summary_generation`, \n `title_generation_prompt`,\n `text2sql`,\n `agg_table`,\n `column_metadata`,\n `prompt generator`\n .", "title": "Service" }, "transaction_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Transaction uuid to identify entries added per request.", "title": "Transaction Uuid" }, "high_confidence_status": { "anyOf": [ { "enum": [ "requested", "approved", "declined" ], "type": "string" }, { "type": "null" } ], "default": null, "description": "stores if an io is high confidence or not, possible values ('requested', 'approved', 'declined')", "title": "High Confidence Status" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "comment made to while changing confidence of an io", "title": "Confidence Change Comment" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Qna thread uuid to identify entries added per request.", "title": "Qna Thread Uuid" }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Process state of the qna io", "title": "Process State" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Uuid of current qna conversation", "title": "Qna Conversation Uuid" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to indicate if the query is a followup query", "title": "Flag Followup" }, "flag_fuzzy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Flag to indicate if fuzzy match is enabled", "title": "Flag Fuzzy" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA IO", "title": "Is Favorite" } } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field created_by: str | None = None
User that created the qna io
- field created_ts: datetime | None = None
Unix time in milliseconds generated at creation time.
- field modified_by: str | None = None
User that modified the qna io
- field modified_ts: datetime | None = None
Unix time in milliseconds generated at last modification time.
- pydantic model V1QnaIoResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1QnaIoResponseList", "type": "array", "$defs": { "V1QnaIoResponse": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of metadata (foreign key)", "title": "Metadata Uuid" }, "user_input": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "user input of qna io", "title": "User Input" }, "query_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "query type of qna io", "title": "Query Type" }, "input_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding ids of qna io", "title": "Input Embedding Ids" }, "output_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding ids of qna io", "title": "Output Embedding Ids" }, "context_embedding_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "context embedding ids of qna io", "title": "Context Embedding Ids" }, "few_shot_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "few shot ids of qna io", "title": "Few Shot Ids" }, "input_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embeddings", "title": "Input Embedding" }, "raw_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "raw output embeddings", "title": "Raw Output Embedding" }, "final_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final output embeddings", "title": "Final Output Embedding" }, "input_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embedding cluster ids", "title": "Input Embedding Cluster Id" }, "raw_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "output embedding cluster ids", "title": "Raw Output Embedding Cluster Id" }, "final_output_embedding_cluster_id": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final embedding cluster ids", "title": "Final Output Embedding Cluster Id" }, "tx_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "tx id", "title": "Tx Id" }, "tx_time": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Tx Time" }, "llm_prompt": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "llm prompt of qna io", "title": "Llm Prompt" }, "raw_output": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "raw output of qna io", "title": "Raw Output" }, "final_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "final output of qna io", "title": "Final Output" }, "anti_hallucination_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "anti-hallucination output of qna io's raw output", "title": "Anti Hallucination Output" }, "decomposed_queries": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "decomposed queries of qna io", "title": "Decomposed Queries" }, "exceptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "exceptions of qna io", "title": "Exceptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of sources", "title": "Sources" }, "use_case": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "use case", "title": "Use Case" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "feedback value of qna io", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "feedback comment of qna io", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "active", "description": "status of qna io", "title": "Status" }, "jobs": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "A mapping for job types to job ids for jobs associated to io entry", "title": "Jobs" }, "derived_features": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional features needed for LLM monitoring", "title": "Derived Features" }, "service": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "LLM monitoring service. Values include: \n `summarization`, \n `chart`, \n `agg_chart`,\n `sanitization`,\n `summary_generation`, \n `title_generation_prompt`,\n `text2sql`,\n `agg_table`,\n `column_metadata`,\n `prompt generator`\n .", "title": "Service" }, "transaction_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Transaction uuid to identify entries added per request.", "title": "Transaction Uuid" }, "high_confidence_status": { "anyOf": [ { "enum": [ "requested", "approved", "declined" ], "type": "string" }, { "type": "null" } ], "default": null, "description": "stores if an io is high confidence or not, possible values ('requested', 'approved', 'declined')", "title": "High Confidence Status" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "comment made to while changing confidence of an io", "title": "Confidence Change Comment" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Qna thread uuid to identify entries added per request.", "title": "Qna Thread Uuid" }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Process state of the qna io", "title": "Process State" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Uuid of current qna conversation", "title": "Qna Conversation Uuid" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to indicate if the query is a followup query", "title": "Flag Followup" }, "flag_fuzzy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Flag to indicate if fuzzy match is enabled", "title": "Flag Fuzzy" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA IO", "title": "Is Favorite" } }, "title": "V1QnaIoResponse", "type": "object" } }, "items": { "$ref": "#/$defs/V1QnaIoResponse" } }
- field root: List[V1QnaIoResponse] [Required]
- pydantic model V1QnaIoSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1QnaIoSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "anyOf": [ { "$ref": "#/$defs/V1QnaIoFilters" }, { "type": "null" } ], "description": "Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved." } }, "$defs": { "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" }, "V1QnaIoFilters": { "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of created_by for this operation.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of uuids for this operation", "title": "Uuids" }, "name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of names for this operation.", "title": "Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses for this operation.", "title": "Status" }, "metadata_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata_uuid for this operation", "title": "Metadata Uuids" }, "services": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of services.", "title": "Services" }, "transaction_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of transaction ids.", "title": "Transaction Uuids" }, "qna_thread_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of transaction ids.", "title": "Qna Thread Uuids" }, "source": { "anyOf": [ { "items": { "items": { "type": "string" }, "type": "array" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "source for qnaio", "title": "Source" }, "high_confidence_statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "source for qnaio", "title": "High Confidence Statuses" }, "qna_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of conversation ids.", "title": "Qna Conversation Uuids" }, "query_types": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query_types", "title": "Query Types" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag_followup", "title": "Flag Followup" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag to make favorite QNA IO", "title": "Is Favorite" }, "favorites_toggle": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to perform favorites toggle functionality", "title": "Favorites Toggle" } }, "title": "V1QnaIoFilters", "type": "object" } } }
- field filters: V1QnaIoFilters | None = <class 'vianops_client.models.qnastore.qna_io.V1QnaIoFilters'>
Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved.
- pydantic model V1QnaIoUpdates
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaIoUpdates", "type": "object", "properties": { "anti_hallucination_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "anti-hallucination output of qna io's raw output", "title": "Anti Hallucination Output" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "active", "description": "status of qna io", "title": "Status" }, "jobs": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "A mapping for job types to job ids for jobs associated to io entry", "title": "Jobs" }, "derived_features": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Additional features needed for LLM monitoring", "title": "Derived Features" }, "input_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "input embeddings", "title": "Input Embedding" }, "raw_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "raw output embeddings", "title": "Raw Output Embedding" }, "raw_output": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "raw output of qna io", "title": "Raw Output" }, "final_output_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "final output embeddings", "title": "Final Output Embedding" }, "final_output": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "final output of qna io", "title": "Final Output" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Feedback value. Posive feedback store as `true`, and negative feedback stored as 'false'.", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Feedback comment.", "title": "Feedback Comment" }, "high_confidence_status": { "anyOf": [ { "enum": [ "requested", "approved", "declined" ], "type": "string" }, { "type": "null" } ], "default": null, "description": "High confidence change status.", "title": "High Confidence Status" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Comment regarding confidence change (promotion).", "title": "Confidence Change Comment" }, "filters": { "anyOf": [ { "$ref": "#/$defs/V1QnaIoFilters" }, { "type": "null" } ], "description": "Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved." }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Process state of the qna io", "title": "Process State" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA IO", "title": "Is Favorite" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA IO", "title": "Is Pinned" } }, "$defs": { "V1QnaIoFilters": { "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of created_by for this operation.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of uuids for this operation", "title": "Uuids" }, "name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of names for this operation.", "title": "Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses for this operation.", "title": "Status" }, "metadata_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata_uuid for this operation", "title": "Metadata Uuids" }, "services": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of services.", "title": "Services" }, "transaction_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of transaction ids.", "title": "Transaction Uuids" }, "qna_thread_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of transaction ids.", "title": "Qna Thread Uuids" }, "source": { "anyOf": [ { "items": { "items": { "type": "string" }, "type": "array" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "source for qnaio", "title": "Source" }, "high_confidence_statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "source for qnaio", "title": "High Confidence Statuses" }, "qna_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of conversation ids.", "title": "Qna Conversation Uuids" }, "query_types": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query_types", "title": "Query Types" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag_followup", "title": "Flag Followup" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag to pin QNA IO", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of flag to make favorite QNA IO", "title": "Is Favorite" }, "favorites_toggle": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Flag to perform favorites toggle functionality", "title": "Favorites Toggle" } }, "title": "V1QnaIoFilters", "type": "object" } } }
- Fields:
- field anti_hallucination_output: dict | None = None
anti-hallucination output of qna io’s raw output
- field confidence_change_comment: str | None = None
Comment regarding confidence change (promotion).
- field derived_features: dict | None = None
Additional features needed for LLM monitoring
- field feedback_comment: str | None = None
Feedback comment.
- field feedback_value: bool | None = None
Feedback value. Posive feedback store as true, and negative feedback stored as ‘false’.
- field filters: V1QnaIoFilters | None = <class 'vianops_client.models.qnastore.qna_io.V1QnaIoFilters'>
Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved.
- field final_output: dict | None = None
final output of qna io
- field final_output_embedding: List[float] | None = None
final output embeddings
- field high_confidence_status: Literal['requested', 'approved', 'declined'] | None = None
High confidence change status.
- field input_embedding: List[float] | None = None
input embeddings
- field is_favorite: bool | None = None
flag to make favorite QNA IO
- field is_pinned: bool | None = None
flag to pin QNA IO
- field jobs: dict | None = None
A mapping for job types to job ids for jobs associated to io entry
- field process_state: dict | None = None
Process state of the qna io
- field raw_output: str | None = None
raw output of qna io
- field raw_output_embedding: List[float] | None = None
raw output embeddings
- field status: str | None = 'active'
status of qna io
- pydantic model V1QnaIoUserQueries
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaIoUserQueries", "type": "object", "properties": { "items": { "items": { "$ref": "#/$defs/V1Queries" }, "title": "Items", "type": "array" } }, "$defs": { "V1Queries": { "properties": { "uuid": { "title": "Uuid", "type": "string" }, "metadata_uuid": { "title": "Metadata Uuid", "type": "string" }, "user_input": { "title": "User Input", "type": "string" }, "confidence_change_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Confidence Change Comment" }, "high_confidence_status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "High Confidence Status" }, "raw_output": { "title": "Raw Output", "type": "string" }, "final_output": { "title": "Final Output", "type": "object" } }, "required": [ "uuid", "metadata_uuid", "user_input", "raw_output", "final_output" ], "title": "V1Queries", "type": "object" } }, "required": [ "items" ] }
- field items: List[V1Queries] [Required]
vianops_client.models.qnastore.qna_metadata module
- pydantic model V1AutoGenModel
Bases:
BaseModel
Show JSON schema
{ "title": "V1AutoGenModel", "type": "object", "properties": { "job_id": { "title": "Job Id", "type": "string" }, "job_type": { "title": "Job Type", "type": "string" }, "job_description": { "default": null, "title": "Job Description", "type": "string" }, "user_id": { "title": "User Id", "type": "string" }, "status": { "title": "Status", "type": "string" }, "statusdetails": { "title": "Statusdetails", "type": "string" }, "result": { "title": "Result", "type": "string" }, "exception": { "title": "Exception", "type": "string" }, "created": { "title": "Created", "type": "string" }, "started": { "title": "Started", "type": "string" }, "finished": { "title": "Finished", "type": "string" }, "timestamp": { "title": "Timestamp", "type": "number" }, "configmap": { "title": "Configmap", "type": "string" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "result", "exception", "created", "started", "finished", "timestamp", "configmap" ] }
- Fields:
- field configmap: str [Required]
- field created: str [Required]
- field exception: str [Required]
- field finished: str [Required]
- field job_description: str = None
- field job_id: str [Required]
- field job_type: str [Required]
- field result: str [Required]
- field started: str [Required]
- field status: str [Required]
- field statusdetails: str [Required]
- field timestamp: float [Required]
- field user_id: str [Required]
- pydantic model V1BaseQNAMetadataModel
Bases:
BaseModel
Show JSON schema
{ "title": "V1BaseQNAMetadataModel", "type": "object", "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "Config value used to identify qna metadata's queries.", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" } } }
- Fields:
- field allowed_embedding_models: List[str] | None = None
Embedding Models allowed for use
- field allowed_llms: List[str] | None = None
LLMs allowed for use
- field config: dict | None = {}
Config value used to identify qna metadata’s queries.
- field created_by: str | None = None
User who created the metadata
- field created_ts: datetime | None = None
Unix time in milliseconds generated at creation time.
- field description: str | None = None
metadata description
- field external_connection_name: str | None = None
External connection name
- field modified_by: str | None = None
User who modified the metadata
- field modified_ts: datetime | None = None
Unix time in milliseconds generated at last modification time.
- field preferred_embedding_model: str | None = None
preferred Embedding Model
- field preferred_llm: Dict | None = None
preferred LLM
- field project_name: str | None = None
Project name
- field status: str | None = None
Status of the metadata
- field version: int | None = None
Version of the metadata
- pydantic model V1BaseQNAMetadataModelList
Bases:
RootModel
Show JSON schema
{ "title": "V1BaseQNAMetadataModelList", "type": "array", "$defs": { "V1BaseQNAMetadataModel": { "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "Config value used to identify qna metadata's queries.", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" } }, "title": "V1BaseQNAMetadataModel", "type": "object" } }, "items": { "$ref": "#/$defs/V1BaseQNAMetadataModel" } }
- field root: List[V1BaseQNAMetadataModel] [Required]
- pydantic model V1ChartFewshotItem
Bases:
BaseModel
Show JSON schema
{ "title": "V1ChartFewshotItem", "type": "object", "properties": { "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "chart type", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "created by", "title": "Created By" }, "query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql query", "title": "Query" }, "similarity_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "similarity score", "title": "Similarity Score" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql response", "title": "Sql Query" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of template", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "type of question", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "complexity of query", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "is a suggested query", "title": "Is Suggested" } } }
- Fields:
- field chart_type: str | None = None
chart type
- field complexity: str | None = None
complexity of query
- field created_by: str | None = None
created by
- field is_suggested: bool | None = False
is a suggested query
- field query: str | None = None
golden sql query
- field question_type: str | None = None
type of question
- field similarity_score: float | None = None
similarity score
- field sql_query: str | None = None
golden sql response
- field template_name: str | None = None
name of template
- pydantic model V1ModelParams
Bases:
BaseModel
Show JSON schema
{ "title": "V1ModelParams", "type": "object", "properties": { "model_name_ext": { "description": "Name of the model to clone, must match the model name in the system.", "title": "Model Name Ext", "type": "string" }, "api_token": { "default": null, "description": "API token for the model", "title": "Api Token", "type": "string" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "ext_conn_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "Ext Conn Name" }, "ext_conn_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection URL", "title": "Ext Conn Url" }, "threshold_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Threshold value", "title": "Threshold Value" }, "num_queries": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of GSQL queries to retrieve as example", "title": "Num Queries" }, "app_env": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Application environment", "title": "App Env" }, "api_endpoint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "API endpoint", "title": "Api Endpoint" }, "api_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "API version", "title": "Api Version" }, "api_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "API type", "title": "Api Type" }, "task_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Task type", "title": "Task Type" }, "azure_endpoint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Azure endpoint", "title": "Azure Endpoint" }, "model_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model type", "title": "Model Type" }, "model_class": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model wrapper class", "title": "Model Class" } }, "required": [ "model_name_ext" ] }
- Config:
protected_namespaces: tuple = ()
- Fields:
- field api_endpoint: str | None = None
API endpoint
- field api_token: str = None
API token for the model
- field api_type: str | None = None
API type
- field api_version: str | None = None
API version
- field app_env: str | None = None
Application environment
- field azure_endpoint: str | None = None
Azure endpoint
- field ext_conn_name: str | None = None
External connection name
- field ext_conn_url: str | None = None
External connection URL
- field model_class: str | None = None
Model wrapper class
- field model_name_ext: str [Required]
Name of the model to clone, must match the model name in the system.
- field model_type: str | None = None
Model type
- field num_queries: int | None = None
Number of GSQL queries to retrieve as example
- field project_name: str | None = None
Project name
- field task_type: str | None = None
Task type
- field threshold_value: float | None = None
Threshold value
- pydantic model V1PromptGenerationModel
Bases:
BaseModel
Show JSON schema
{ "title": "V1PromptGenerationModel", "type": "object", "properties": { "query": { "anyOf": [ { "type": "string" }, { "type": "object" }, { "items": {}, "type": "array" } ], "title": "Query" }, "qna_metadata_name": { "title": "Qna Metadata Name", "type": "string" }, "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Uuid" } }, "required": [ "query", "qna_metadata_name" ] }
- field qna_metadata_name: str [Required]
- field query: str | dict | list [Required]
- field uuid: str | None = None
- pydantic model V1PromptGenerationResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1PromptGenerationResponse", "type": "object", "properties": { "prompt": { "anyOf": [ { "type": "object" }, { "type": "string" } ], "title": "Prompt" } }, "required": [ "prompt" ] }
- Fields:
- field prompt: dict | str [Required]
- pydantic model V1QNACreateDBRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNACreateDBRequest", "type": "object", "properties": { "db_name": { "maxLength": 128, "title": "Db Name", "type": "string" }, "table_schema_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Table schema name", "title": "Table Schema Name" }, "conn_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Connection name", "title": "Conn Name" }, "parent_conn_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Parent database name", "title": "Parent Conn Name" }, "views_data": { "anyOf": [ { "additionalProperties": { "type": "object" }, "type": "object" }, { "type": "null" } ], "default": null, "description": "Views data", "title": "Views Data" }, "hcf_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "3_3_0_r_2", "description": "hilaCF version", "title": "Hcf Version" }, "ro_username": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Read only username", "title": "Ro Username" }, "ro_password": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Read only password", "title": "Ro Password" }, "qnametadata_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "3_3_0_r_2", "description": "default global qnametadata version", "title": "Qnametadata Version" } }, "required": [ "db_name" ] }
- Fields:
- field conn_name: str | None = None
Connection name
- field db_name: str [Required]
- Constraints:
max_length = 128
- field hcf_version: str | None = '3_3_0_r_2'
hilaCF version
- field parent_conn_name: str | None = None
Parent database name
- field qnametadata_version: str | None = '3_3_0_r_2'
default global qnametadata version
- field ro_password: str | None = None
Read only password
- field ro_username: str | None = None
Read only username
- field table_schema_name: str | None = None
Table schema name
- field views_data: Dict[str, Dict] | None = None
Views data
- pydantic model V1QNACreateDBResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNACreateDBResponse", "type": "object", "properties": { "status": { "title": "Status", "type": "string" }, "message": { "title": "Message", "type": "string" } }, "required": [ "status", "message" ] }
- Fields:
- field message: str [Required]
- field status: str [Required]
- pydantic model V1QNAMetadataCloneRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataCloneRequest", "type": "object", "properties": { "base_metadata": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "default_hcfv2_metadata", "description": "Name of the source metadata", "title": "Base Metadata" }, "update_fields": { "additionalProperties": { "anyOf": [ { "type": "string" }, { "type": "object" }, { "items": {}, "type": "array" } ] }, "description": "Fields to update/add. Must at least contain the new name.", "title": "Update Fields", "type": "object" }, "models_dict": { "anyOf": [ { "additionalProperties": { "$ref": "#/$defs/V1ModelParams" }, "type": "object" }, { "type": "null" } ], "default": null, "description": "Dictionary of models and their parameters. Model names must match those installed in the system.", "title": "Models Dict" }, "run_setup_models_cf": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Flag to run setup_models_cf endpoint and update their prompts with the data patterns script.", "title": "Run Setup Models Cf" }, "qnametadata_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "4_0_0_r_1", "description": "qnametadata version required for default metadata", "title": "Qnametadata Version" } }, "$defs": { "V1ModelParams": { "properties": { "model_name_ext": { "description": "Name of the model to clone, must match the model name in the system.", "title": "Model Name Ext", "type": "string" }, "api_token": { "default": null, "description": "API token for the model", "title": "Api Token", "type": "string" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "ext_conn_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "Ext Conn Name" }, "ext_conn_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection URL", "title": "Ext Conn Url" }, "threshold_value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Threshold value", "title": "Threshold Value" }, "num_queries": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of GSQL queries to retrieve as example", "title": "Num Queries" }, "app_env": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Application environment", "title": "App Env" }, "api_endpoint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "API endpoint", "title": "Api Endpoint" }, "api_version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "API version", "title": "Api Version" }, "api_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "API type", "title": "Api Type" }, "task_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Task type", "title": "Task Type" }, "azure_endpoint": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Azure endpoint", "title": "Azure Endpoint" }, "model_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model type", "title": "Model Type" }, "model_class": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model wrapper class", "title": "Model Class" } }, "required": [ "model_name_ext" ], "title": "V1ModelParams", "type": "object" } }, "required": [ "update_fields" ] }
- Fields:
- Validators:
check_update_fields
»all fields
- field base_metadata: str | None = 'default_hcfv2_metadata'
Name of the source metadata
- Validated by:
- field models_dict: Dict[str, V1ModelParams] | None = None
Dictionary of models and their parameters. Model names must match those installed in the system.
- Validated by:
- field qnametadata_version: str | None = '4_0_0_r_1'
qnametadata version required for default metadata
- Validated by:
- field run_setup_models_cf: bool | None = True
Flag to run setup_models_cf endpoint and update their prompts with the data patterns script.
- Validated by:
- field update_fields: Dict[str, str | Dict | List] [Required]
Fields to update/add. Must at least contain the new name.
- Validated by:
- validator check_update_fields » all fields
- pydantic model V1QNAMetadataCloneResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataCloneResponse", "type": "object", "properties": { "model_setup_response": { "$ref": "#/$defs/V1ModelsModelList" }, "cloned_metadata_response": { "items": { "$ref": "#/$defs/V1QNAMetadataModel" }, "title": "Cloned Metadata Response", "type": "array" }, "autogen_response": { "$ref": "#/$defs/V1JobModel" }, "entityingestion_response": { "anyOf": [ { "$ref": "#/$defs/V1JobModel" }, { "type": "null" } ], "default": null } }, "$defs": { "V1AutoGenModel": { "properties": { "job_id": { "title": "Job Id", "type": "string" }, "job_type": { "title": "Job Type", "type": "string" }, "job_description": { "default": null, "title": "Job Description", "type": "string" }, "user_id": { "title": "User Id", "type": "string" }, "status": { "title": "Status", "type": "string" }, "statusdetails": { "title": "Statusdetails", "type": "string" }, "result": { "title": "Result", "type": "string" }, "exception": { "title": "Exception", "type": "string" }, "created": { "title": "Created", "type": "string" }, "started": { "title": "Started", "type": "string" }, "finished": { "title": "Finished", "type": "string" }, "timestamp": { "title": "Timestamp", "type": "number" }, "configmap": { "title": "Configmap", "type": "string" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "result", "exception", "created", "started", "finished", "timestamp", "configmap" ], "title": "V1AutoGenModel", "type": "object" }, "V1JobModel": { "properties": { "job_id": { "description": "The job id.", "title": "Job Id", "type": "string" }, "job_type": { "description": "The job type. Supported values: `dataloading`, `dataprofiling`, `driftdetection`, `modelperformance`, `preprocessing`.", "title": "Job Type", "type": "string" }, "user_id": { "description": "User id.", "title": "User Id", "type": "string" }, "run_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Run id.", "title": "Run Id" }, "status": { "description": "Job status. Supported values: `queued`, `done`.", "title": "Status", "type": "string" }, "statusdetails": { "description": "Status details.", "title": "Statusdetails", "type": "string" }, "result": { "anyOf": [ {}, { "type": "null" } ], "default": null, "description": "Job results, if job status is `done`.", "title": "Result" }, "exception": { "description": "Exception details, if an exeption occurred while running the job.", "title": "Exception", "type": "string" }, "created": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "The date and time the job pod was created.", "title": "Created" }, "started": { "description": "The date and time the job started.", "title": "Started", "type": "string" }, "finished": { "description": "The date and time the job finished.", "title": "Finished", "type": "string" }, "timestamp": { "description": "Job timestamp.", "title": "Timestamp", "type": "number" }, "configmap": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Configuration map.", "title": "Configmap" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "exception", "started", "finished", "timestamp" ], "title": "V1JobModel", "type": "object" }, "V1ModelTagsModel": { "example": { "created_by": "user1", "created_ts": 1675292368, "model_uuid": "abc-123-def-456", "modified_by": "user1", "modified_ts": 1675292368, "name": "Example Model Tag", "status": "active", "uuid": "xyz-789-rst-456", "value": { "key": "value" } }, "properties": { "model_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the model that the tag is associated with.", "title": "Model Uuid" }, "name": { "description": "Name of the model tag.", "title": "Name", "type": "string" }, "value": { "anyOf": [ { "type": "number" }, { "type": "integer" }, { "type": "string" }, { "items": {}, "type": "array" }, { "items": { "type": "object" }, "type": "array" }, { "type": "object" } ], "description": "Value of the model tag.", "title": "Value" }, "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the model tag.", "title": "Uuid" }, "status": { "description": "Current status of the model tag. This field is case-insensitive. Possible values: `active`(default), `inactive` , `archived`, `delete`.", "title": "Status", "type": "string" }, "created_ts": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the model", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the model", "title": "Modified By" } }, "required": [ "name", "value", "status" ], "title": "V1ModelTagsModel", "type": "object" }, "V1ModelsModel": { "example": { "created_by": "user1", "created_ts": 1675292368, "modified_by": "user1", "modified_ts": 1675292368, "name": "Example Model", "project_uuid": "0", "stage": "Example model stage", "status": "active", "uuid": "0", "version": "1.0" }, "properties": { "version": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model version", "title": "Version" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model status", "title": "Status" }, "stage": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Model stage", "title": "Stage" }, "project_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project uuid associated with the model.", "title": "Project Uuid" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the model.", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the model.", "title": "Modified By" }, "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the model.", "title": "Uuid" }, "name": { "description": "Name of the model", "title": "Name", "type": "string" }, "tags": { "anyOf": [ { "items": { "$ref": "#/$defs/V1ModelTagsModel" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Model tags associated with the model.", "title": "Tags" } }, "required": [ "name" ], "title": "V1ModelsModel", "type": "object" }, "V1ModelsModelList": { "items": { "$ref": "#/$defs/V1ModelsModel" }, "title": "V1ModelsModelList", "type": "array" }, "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataCompanyMetadata": { "properties": { "parent_company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Parent Company Name" }, "company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Name" }, "company_code": { "title": "Company Code", "type": "string" }, "company_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Country" }, "company_currency": { "title": "Company Currency", "type": "string" }, "global_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Global Currency" } }, "required": [ "company_code", "company_currency" ], "title": "V1QNAMetadataCompanyMetadata", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataModel": { "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" }, "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" }, "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "entity_type": "single", "job_status": { "configmap": "config-autogen-queue-30202017278035", "created": "2023-10-30 20:20:17.295084", "exception": "", "finished": "", "job_description": null, "job_id": "autogen-queue-30202017278035", "job_type": "autogen", "result": "", "started": "", "status": "queued", "statusdetails": "", "timestamp": 1698697217295.0898, "user_id": "vianai" }, "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" }, "project_name": "LLM Project" }, "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of config", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" }, "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the metadata.", "title": "Uuid" }, "qnametadata_index": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Index name of the metadata.", "title": "Qnametadata Index" }, "name": { "description": "Name of the metadata", "title": "Name", "type": "string" }, "data": { "$ref": "#/$defs/V1QNAMetadataData" }, "job_status": { "anyOf": [ { "$ref": "#/$defs/V1AutoGenModel" }, { "type": "null" } ], "default": null }, "generate_alternate_queries": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Alternate Queries" }, "generate_golden_sql": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Golden Sql" }, "entity_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "single", "description": "Entity type of the metadata", "title": "Entity Type" }, "default_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Default currency of the metadata", "title": "Default Currency" }, "company_metadata": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataCompanyMetadata" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Company Metadata" } }, "required": [ "name", "data" ], "title": "V1QNAMetadataModel", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "required": [ "model_setup_response", "cloned_metadata_response", "autogen_response" ] }
- Config:
protected_namespaces: tuple = ()
- Fields:
autogen_response (vianops_client.models.jobmaker.job.V1JobModel)
cloned_metadata_response (List[vianops_client.models.qnastore.qna_metadata.V1QNAMetadataModel])
entityingestion_response (vianops_client.models.jobmaker.job.V1JobModel | None)
model_setup_response (vianops_client.models.modelstore.models.V1ModelsModelList)
- field autogen_response: V1JobModel [Required]
- field cloned_metadata_response: List[V1QNAMetadataModel] [Required]
- field entityingestion_response: V1JobModel | None = None
- field model_setup_response: V1ModelsModelList [Required]
- pydantic model V1QNAMetadataColumn
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataColumn", "type": "object", "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "required": [ "name" ] }
- Config:
from_attributes: bool = True
json_schema_extra: dict = {‘example’: {‘name’: ‘ProductId’, ‘data_type’: ‘bigint’, ‘description’: ‘Product Id’, ‘categorical’: False}}
- Fields:
- field aliases: List[str] | None = None
- field categorical: bool | None = False
- field data_type: str | None = None
- field description: str | None = None
- field name: str [Required]
- field sample_values: List[Any] | None = None
- pydantic model V1QNAMetadataData
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataData", "type": "object", "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "$defs": { "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "required": [ "tables", "queries" ] }
- Fields:
- field connection_name: str | None = None
- field max_retry_attempts: int | None = 1
- field queries: List[V1QNAMetadataQuery] [Required]
- field rules: str | None = None
- field sql_match_threshold: float | None = None
- field tables: List[V1QNAMetadataTable] [Required]
- field top_match_similarity_threshold: float | None = None
- field use_intent_classification: bool | None = False
- field user_top_match_similarity_threshold: float | None = None
- pydantic model V1QNAMetadataDimensionsResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataDimensionsResponse", "type": "object", "properties": { "dimensions": { "additionalProperties": { "type": "object" }, "title": "Dimensions", "type": "object" } }, "required": [ "dimensions" ] }
- Fields:
- field dimensions: Dict[str, Dict] [Required]
- pydantic model V1QNAMetadataFilters
Bases:
V1FiltersCommon
Show JSON schema
{ "title": "V1QNAMetadataFilters", "type": "object", "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "data": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data for this operation.", "title": "Data" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of allowed_llm types for this operation.", "title": "Allowed Llms" }, "preferred_llms": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of preferred_llm for this operation.", "title": "Preferred Llms" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of allowed_embedding_models for this operation.", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of preferred_embedding_model for this operation.", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of project_name for this operation.", "title": "Project Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Status" }, "entity_types": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Entity type of the metadata", "title": "Entity Types" }, "default_currencies": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Default currency of the metadata", "title": "Default Currencies" } }, "example": { "names": [ "Example metdata" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
alias_generator: function = <function V1QNAMetadataFilters.<lambda> at 0x7f98c4f239c0>
json_schema_extra: dict = {‘example’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example metdata’]}}
- Fields:
- field allowed_embedding_models: List[str] | None = None
List of allowed_embedding_models for this operation.
- field allowed_llms: List[str] | None = None
List of allowed_llm types for this operation.
- field data: List[dict] | None = None
List of data for this operation.
- field default_currency: List[str] | None = None (alias 'default_currencies')
Default currency of the metadata
- field description: List[str] | None = None (alias 'descriptions')
List of descriptions for this operation.
- field entity_type: List[str] | None = None (alias 'entity_types')
Entity type of the metadata
- field name: List[str] | None = None (alias 'names')
List of metadata names for this operation.
- field preferred_embedding_model: List[str] | None = None
List of preferred_embedding_model for this operation.
- field preferred_llm: Dict | None = None (alias 'preferred_llms')
Dict of preferred_llm for this operation.
- field project_name: List[str] | None = None
List of project_name for this operation.
- field status: List[str] | None = None
List of status for this operation.
- field uuid: List[str] | None = None (alias 'uuids')
List of metadata uuids for this operation.
- pydantic model V1QNAMetadataGenerateRequest
Bases:
V1QNAMetadataGenerateResponse
Show JSON schema
{ "title": "V1QNAMetadataGenerateRequest", "type": "object", "properties": { "name": { "description": "Name of the metadata", "title": "Name", "type": "string" }, "external_connection_name": { "description": "External connection name", "title": "External Connection Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Models", "title": "Preferred Embedding Model" }, "data": { "$ref": "#/$defs/V1QNAMetadataData" }, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Table schema name", "title": "Schema" }, "max_sample_values": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 10, "description": "Number of sample values", "title": "Max Sample Values" }, "conn_type": { "default": "postgresql", "description": "Database connection type", "title": "Conn Type", "type": "string" }, "tables": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of table names", "title": "Tables" }, "columns": { "anyOf": [ { "additionalProperties": { "items": { "type": "string" }, "type": "array" }, "type": "object" }, { "type": "null" } ], "default": null, "description": "Dictionary of table names and their corresponding column names", "title": "Columns" } }, "$defs": { "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": [ { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" } ], "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": [ { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" } ], "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "external_connection_name": "sample_ext_connection", "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" } }, "required": [ "name", "external_connection_name", "data" ] }
- Config:
from_attributes: bool = True
json_schema_extra: dict = {‘example’: {‘name’: ‘sample_metadata’, ‘external_connection_name’: ‘sample_ext_connection’, ‘description’: ‘Sample for metadata’, ‘allowed_llms’: [‘lang_model1’, ‘lang_model2’], ‘preferred_llm’: {‘summarization’: ‘lang_model1’, ‘chart’: ‘lang_model1’, ‘agg_chart’: ‘lang_model1’, ‘sanitization’: ‘lang_model1’, ‘summary_generation’: ‘lang_model1’, ‘title_generation_prompt’: ‘lang_model2’, ‘text2sql’: ‘lang_model2’, ‘agg_table’: ‘lang_model2’, ‘column_metadata’: ‘lang_model2’, ‘prompt_generator’: ‘lang_model2’}, ‘allowed_embedding_models’: [‘embedding_model1’, ‘embedding_model2’], ‘preferred_embedding_model’: ‘embedding_model1’, ‘data’: {‘connection_name’: ‘sample_ext_connection’, ‘tables’: [{‘name’: ‘Table 1’, ‘description’: ‘Sample Table 1’, ‘columns’: [{‘name’: ‘Col1’, ‘data_type’: ‘string’, ‘description’: ‘’, ‘aliases’: [‘string_alias1’, ‘string_alias2’], ‘categorical’: True, ‘sample_values’: [‘sdasd’, ‘vdsvd’]}, {‘name’: ‘Col2’, ‘data_type’: ‘datetime’, ‘description’: ‘’, ‘aliases’: [‘datetime_alias1’, ‘datetime_alias2’], ‘categorical’: False, ‘sample_values’: [‘10/10/1900’]}, {‘name’: ‘Col3’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: False, ‘sample_values’: [1, 3, 4]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col1’, ‘Col2’]}, ‘foreign_keys’: [{‘name’: ‘fk_1’, ‘column_names’: [‘Col3’], ‘reference_table’: ‘Table 2’, ‘reference_column_names’: [‘Col2T2’]}], ‘rules’: ‘’}, {‘name’: ‘Table 2’, ‘description’: ‘Sample Table 2’, ‘columns’: [{‘name’: ‘Col2T2’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: True, ‘sample_values’: [1, 2, 3]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col2T2’]}, ‘foreign_keys’: [{‘name’: ‘fk_1’, ‘column_names’: [‘Col2T2’], ‘reference_table’: ‘Table 1’, ‘reference_column_names’: [‘Col3’]}], ‘rules’: ‘’}], ‘queries’: [{‘natural_language_query’: ‘give me all the cost of goods sold transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR=’0L’”, ‘description’: None}, {‘natural_language_query’: ‘Give me all the travel expense transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR=’0L’”, ‘description’: None}], ‘rules’: ‘n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.n * If years or months are not mentioned then group by DATES for cost related queries.n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.n * Always group by months if the query asks for data for any year.n ‘}}}
- Fields:
- field columns: Dict[str, List[str]] | None = None
Dictionary of table names and their corresponding column names
- field conn_type: str = 'postgresql'
Database connection type
- field max_sample_values: int | None = 10
Number of sample values
- field schema_name: str | None = None (alias 'schema')
Table schema name
- field tables: List[str] | None = None
List of table names
- pydantic model V1QNAMetadataGenerateResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataGenerateResponse", "type": "object", "properties": { "name": { "description": "Name of the metadata", "title": "Name", "type": "string" }, "external_connection_name": { "description": "External connection name", "title": "External Connection Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Models", "title": "Preferred Embedding Model" }, "data": { "$ref": "#/$defs/V1QNAMetadataData" } }, "$defs": { "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": [ { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" } ], "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": [ { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" } ], "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "external_connection_name": "sample_ext_connection", "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" } }, "required": [ "name", "external_connection_name", "data" ] }
- Config:
from_attributes: bool = True
json_schema_extra: dict = {‘example’: {‘name’: ‘sample_metadata’, ‘external_connection_name’: ‘sample_ext_connection’, ‘description’: ‘Sample for metadata’, ‘allowed_llms’: [‘lang_model1’, ‘lang_model2’], ‘preferred_llm’: {‘summarization’: ‘lang_model1’, ‘chart’: ‘lang_model1’, ‘agg_chart’: ‘lang_model1’, ‘sanitization’: ‘lang_model1’, ‘summary_generation’: ‘lang_model1’, ‘title_generation_prompt’: ‘lang_model2’, ‘text2sql’: ‘lang_model2’, ‘agg_table’: ‘lang_model2’, ‘column_metadata’: ‘lang_model2’, ‘prompt_generator’: ‘lang_model2’}, ‘allowed_embedding_models’: [‘embedding_model1’, ‘embedding_model2’], ‘preferred_embedding_model’: ‘embedding_model1’, ‘data’: {‘connection_name’: ‘sample_ext_connection’, ‘tables’: [{‘name’: ‘Table 1’, ‘description’: ‘Sample Table 1’, ‘columns’: [{‘name’: ‘Col1’, ‘data_type’: ‘string’, ‘description’: ‘’, ‘aliases’: [‘string_alias1’, ‘string_alias2’], ‘categorical’: True, ‘sample_values’: [‘sdasd’, ‘vdsvd’]}, {‘name’: ‘Col2’, ‘data_type’: ‘datetime’, ‘description’: ‘’, ‘aliases’: [‘datetime_alias1’, ‘datetime_alias2’], ‘categorical’: False, ‘sample_values’: [‘10/10/1900’]}, {‘name’: ‘Col3’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: False, ‘sample_values’: [1, 3, 4]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col1’, ‘Col2’]}, ‘foreign_keys’: [{‘name’: ‘fk_1’, ‘column_names’: [‘Col3’], ‘reference_table’: ‘Table 2’, ‘reference_column_names’: [‘Col2T2’]}], ‘rules’: ‘’}, {‘name’: ‘Table 2’, ‘description’: ‘Sample Table 2’, ‘columns’: [{‘name’: ‘Col2T2’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: True, ‘sample_values’: [1, 2, 3]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col2T2’]}, ‘foreign_keys’: [{‘name’: ‘fk_1’, ‘column_names’: [‘Col2T2’], ‘reference_table’: ‘Table 1’, ‘reference_column_names’: [‘Col3’]}], ‘rules’: ‘’}], ‘queries’: [{‘natural_language_query’: ‘give me all the cost of goods sold transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR=’0L’”, ‘description’: None}, {‘natural_language_query’: ‘Give me all the travel expense transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR=’0L’”, ‘description’: None}], ‘rules’: ‘n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.n * If years or months are not mentioned then group by DATES for cost related queries.n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.n * Always group by months if the query asks for data for any year.n ‘}}}
- Fields:
- field allowed_embedding_models: List[str] | None = None
Embedding Models allowed for use
- field allowed_llms: List[str] | None = None
LLMs allowed for use
- field data: V1QNAMetadataData [Required]
- field description: str | None = None
metadata description
- field external_connection_name: str [Required]
External connection name
- field name: str [Required]
Name of the metadata
- field preferred_embedding_model: str | None = None
preferred Embedding Models
- field preferred_llm: Dict | None = None
Preferred LLM
- pydantic model V1QNAMetadataModel
Bases:
V1BaseQNAMetadataModel
Show JSON schema
{ "title": "V1QNAMetadataModel", "type": "object", "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of config", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" }, "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the metadata.", "title": "Uuid" }, "qnametadata_index": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Index name of the metadata.", "title": "Qnametadata Index" }, "name": { "description": "Name of the metadata", "title": "Name", "type": "string" }, "data": { "$ref": "#/$defs/V1QNAMetadataData" }, "job_status": { "anyOf": [ { "$ref": "#/$defs/V1AutoGenModel" }, { "type": "null" } ], "default": null }, "generate_alternate_queries": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Alternate Queries" }, "generate_golden_sql": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Golden Sql" }, "entity_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "single", "description": "Entity type of the metadata", "title": "Entity Type" }, "default_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Default currency of the metadata", "title": "Default Currency" }, "company_metadata": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataCompanyMetadata" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Company Metadata" } }, "$defs": { "V1AutoGenModel": { "properties": { "job_id": { "title": "Job Id", "type": "string" }, "job_type": { "title": "Job Type", "type": "string" }, "job_description": { "default": null, "title": "Job Description", "type": "string" }, "user_id": { "title": "User Id", "type": "string" }, "status": { "title": "Status", "type": "string" }, "statusdetails": { "title": "Statusdetails", "type": "string" }, "result": { "title": "Result", "type": "string" }, "exception": { "title": "Exception", "type": "string" }, "created": { "title": "Created", "type": "string" }, "started": { "title": "Started", "type": "string" }, "finished": { "title": "Finished", "type": "string" }, "timestamp": { "title": "Timestamp", "type": "number" }, "configmap": { "title": "Configmap", "type": "string" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "result", "exception", "created", "started", "finished", "timestamp", "configmap" ], "title": "V1AutoGenModel", "type": "object" }, "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataCompanyMetadata": { "properties": { "parent_company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Parent Company Name" }, "company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Name" }, "company_code": { "title": "Company Code", "type": "string" }, "company_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Country" }, "company_currency": { "title": "Company Currency", "type": "string" }, "global_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Global Currency" } }, "required": [ "company_code", "company_currency" ], "title": "V1QNAMetadataCompanyMetadata", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" }, "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" }, "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "entity_type": "single", "job_status": { "configmap": "config-autogen-queue-30202017278035", "created": "2023-10-30 20:20:17.295084", "exception": "", "finished": "", "job_description": null, "job_id": "autogen-queue-30202017278035", "job_type": "autogen", "result": "", "started": "", "status": "queued", "statusdetails": "", "timestamp": 1698697217295.0898, "user_id": "vianai" }, "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" }, "project_name": "LLM Project" }, "required": [ "name", "data" ] }
- Config:
from_attributes: bool = True
json_schema_extra: dict = {‘example’: {‘description’: ‘Sample for metadata’, ‘allowed_llms’: [‘lang_model1’, ‘lang_model2’], ‘preferred_llm’: {‘summarization’: ‘lang_model1’, ‘chart’: ‘lang_model1’, ‘agg_chart’: ‘lang_model1’, ‘sanitization’: ‘lang_model1’, ‘summary_generation’: ‘lang_model1’, ‘title_generation_prompt’: ‘lang_model2’, ‘text2sql’: ‘lang_model2’, ‘agg_table’: ‘lang_model2’, ‘column_metadata’: ‘lang_model2’, ‘prompt_generator’: ‘lang_model2’}, ‘allowed_embedding_models’: [‘embedding_model1’, ‘embedding_model2’], ‘preferred_embedding_model’: ‘embedding_model1’, ‘project_name’: ‘LLM Project’, ‘name’: ‘sample_metadata’, ‘entity_type’: ‘single’, ‘data’: {‘connection_name’: ‘sample_ext_connection’, ‘tables’: [{‘name’: ‘Table 1’, ‘description’: ‘Sample Table 1’, ‘columns’: [{‘name’: ‘Col1’, ‘data_type’: ‘string’, ‘description’: ‘’, ‘aliases’: [‘string_alias1’, ‘string_alias2’], ‘categorical’: True, ‘sample_values’: [‘sdasd’, ‘vdsvd’]}, {‘name’: ‘Col2’, ‘data_type’: ‘datetime’, ‘description’: ‘’, ‘aliases’: [‘datetime_alias1’, ‘datetime_alias2’], ‘categorical’: False, ‘sample_values’: [‘10/10/1900’]}, {‘name’: ‘Col3’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: False, ‘sample_values’: [1, 3, 4]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col1’, ‘Col2’]}, ‘foreign_keys’: {‘name’: ‘fk_1’, ‘column_names’: [‘Col3’], ‘reference_table’: ‘Table 2’, ‘reference_column_names’: [‘Col2T2’]}, ‘rules’: ‘’}, {‘name’: ‘Table 2’, ‘description’: ‘Sample Table 2’, ‘columns’: [{‘name’: ‘Col2T2’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: True, ‘sample_values’: [1, 2, 3]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col2T2’]}, ‘foreign_keys’: {‘name’: ‘fk_1’, ‘column_names’: [‘Col2T2’], ‘reference_table’: ‘Table 1’, ‘reference_column_names’: [‘Col3’]}, ‘rules’: ‘’}], ‘queries’: [{‘natural_language_query’: ‘give me all the cost of goods sold transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR=’0L’”, ‘description’: None}, {‘natural_language_query’: ‘Give me all the travel expense transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR=’0L’”, ‘description’: None}], ‘rules’: ‘n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.n * If years or months are not mentioned then group by DATES for cost related queries.n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.n * Always group by months if the query asks for data for any year.n ‘}, ‘job_status’: {‘job_id’: ‘autogen-queue-30202017278035’, ‘job_type’: ‘autogen’, ‘job_description’: None, ‘user_id’: ‘vianai’, ‘status’: ‘queued’, ‘statusdetails’: ‘’, ‘result’: ‘’, ‘exception’: ‘’, ‘created’: ‘2023-10-30 20:20:17.295084’, ‘started’: ‘’, ‘finished’: ‘’, ‘timestamp’: 1698697217295.0898, ‘configmap’: ‘config-autogen-queue-30202017278035’}}}
- Fields:
- field company_metadata: List[V1QNAMetadataCompanyMetadata] | None = None
- field config: dict | None = None
Dict of config
- field data: V1QNAMetadataData [Required]
- field default_currency: str | None = ''
Default currency of the metadata
- field entity_type: str | None = 'single'
Entity type of the metadata
- field generate_alternate_queries: bool | None = False
- field generate_golden_sql: bool | None = False
- field job_status: V1AutoGenModel | None = None
- field name: str [Required]
Name of the metadata
- field qnametadata_index: str | None = None
Index name of the metadata.
- field uuid: str | UUID | None = None
UUID of the metadata.
- pydantic model V1QNAMetadataModelList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAMetadataModelList", "type": "array", "$defs": { "V1AutoGenModel": { "properties": { "job_id": { "title": "Job Id", "type": "string" }, "job_type": { "title": "Job Type", "type": "string" }, "job_description": { "default": null, "title": "Job Description", "type": "string" }, "user_id": { "title": "User Id", "type": "string" }, "status": { "title": "Status", "type": "string" }, "statusdetails": { "title": "Statusdetails", "type": "string" }, "result": { "title": "Result", "type": "string" }, "exception": { "title": "Exception", "type": "string" }, "created": { "title": "Created", "type": "string" }, "started": { "title": "Started", "type": "string" }, "finished": { "title": "Finished", "type": "string" }, "timestamp": { "title": "Timestamp", "type": "number" }, "configmap": { "title": "Configmap", "type": "string" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "result", "exception", "created", "started", "finished", "timestamp", "configmap" ], "title": "V1AutoGenModel", "type": "object" }, "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataCompanyMetadata": { "properties": { "parent_company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Parent Company Name" }, "company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Name" }, "company_code": { "title": "Company Code", "type": "string" }, "company_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Country" }, "company_currency": { "title": "Company Currency", "type": "string" }, "global_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Global Currency" } }, "required": [ "company_code", "company_currency" ], "title": "V1QNAMetadataCompanyMetadata", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" }, "V2QNAMetadataModel": { "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" }, "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" }, "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "entity_type": "single", "job_status": { "configmap": "config-autogen-queue-30202017278035", "created": "2023-10-30 20:20:17.295084", "exception": "", "finished": "", "job_description": null, "job_id": "autogen-queue-30202017278035", "job_type": "autogen", "result": "", "started": "", "status": "queued", "statusdetails": "", "timestamp": 1698697217295.0898, "user_id": "vianai" }, "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" }, "project_name": "LLM Project" }, "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of config", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" }, "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the metadata.", "title": "Uuid" }, "qnametadata_index": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Index name of the metadata.", "title": "Qnametadata Index" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "data": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataData" }, { "type": "null" } ], "default": null }, "job_status": { "anyOf": [ { "$ref": "#/$defs/V1AutoGenModel" }, { "type": "null" } ], "default": null }, "generate_alternate_queries": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Alternate Queries" }, "generate_golden_sql": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Golden Sql" }, "entity_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "single", "description": "Entity type of the metadata", "title": "Entity Type" }, "default_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Default currency of the metadata", "title": "Default Currency" }, "company_metadata": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataCompanyMetadata" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Company Metadata" } }, "title": "V2QNAMetadataModel", "type": "object" } }, "items": { "$ref": "#/$defs/V2QNAMetadataModel" } }
- field root: List[V2QNAMetadataModel] [Required]
- pydantic model V1QNAMetadataPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1QNAMetadataPage", "type": "object", "properties": { "items": { "default": [], "description": "QNA metadata returned by search in page.", "items": { "$ref": "#/$defs/V2QNAMetadataModel" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1AutoGenModel": { "properties": { "job_id": { "title": "Job Id", "type": "string" }, "job_type": { "title": "Job Type", "type": "string" }, "job_description": { "default": null, "title": "Job Description", "type": "string" }, "user_id": { "title": "User Id", "type": "string" }, "status": { "title": "Status", "type": "string" }, "statusdetails": { "title": "Statusdetails", "type": "string" }, "result": { "title": "Result", "type": "string" }, "exception": { "title": "Exception", "type": "string" }, "created": { "title": "Created", "type": "string" }, "started": { "title": "Started", "type": "string" }, "finished": { "title": "Finished", "type": "string" }, "timestamp": { "title": "Timestamp", "type": "number" }, "configmap": { "title": "Configmap", "type": "string" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "result", "exception", "created", "started", "finished", "timestamp", "configmap" ], "title": "V1AutoGenModel", "type": "object" }, "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataCompanyMetadata": { "properties": { "parent_company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Parent Company Name" }, "company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Name" }, "company_code": { "title": "Company Code", "type": "string" }, "company_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Country" }, "company_currency": { "title": "Company Currency", "type": "string" }, "global_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Global Currency" } }, "required": [ "company_code", "company_currency" ], "title": "V1QNAMetadataCompanyMetadata", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" }, "V2QNAMetadataModel": { "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" }, "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" }, "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "entity_type": "single", "job_status": { "configmap": "config-autogen-queue-30202017278035", "created": "2023-10-30 20:20:17.295084", "exception": "", "finished": "", "job_description": null, "job_id": "autogen-queue-30202017278035", "job_type": "autogen", "result": "", "started": "", "status": "queued", "statusdetails": "", "timestamp": 1698697217295.0898, "user_id": "vianai" }, "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" }, "project_name": "LLM Project" }, "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of config", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" }, "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the metadata.", "title": "Uuid" }, "qnametadata_index": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Index name of the metadata.", "title": "Qnametadata Index" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "data": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataData" }, { "type": "null" } ], "default": null }, "job_status": { "anyOf": [ { "$ref": "#/$defs/V1AutoGenModel" }, { "type": "null" } ], "default": null }, "generate_alternate_queries": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Alternate Queries" }, "generate_golden_sql": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Golden Sql" }, "entity_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "single", "description": "Entity type of the metadata", "title": "Entity Type" }, "default_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Default currency of the metadata", "title": "Default Currency" }, "company_metadata": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataCompanyMetadata" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Company Metadata" } }, "title": "V2QNAMetadataModel", "type": "object" } }, "example": { "current_page": 1, "has_next": false, "has_previous": false, "items": [ { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "llamav2-small", "chatgpt3.5" ], "created_by": "user1", "created_ts": 1675292368, "data": {}, "description": "Example description 1", "modified_by": "user1", "modified_ts": 1675292368, "name": "Example metadata 1", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" }, "project_name": "LLM Project", "status": "run", "uuid": "5efc9544-e84a-4a94-9e6d-5774e1c609ab" } ], "next_page": null, "page_size": 100, "pages": 1, "previous_items": 0, "previous_page": null, "total": 1 } }
- Config:
json_schema_extra: dict = {‘example’: {‘items’: [{‘uuid’: ‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘name’: ‘Example metadata 1’, ‘description’: ‘Example description 1’, ‘data’: {}, ‘allowed_llms’: [‘llamav2-small’, ‘chatgpt3.5’], ‘preferred_llm’: {‘summarization’: ‘lang_model1’, ‘chart’: ‘lang_model1’, ‘agg_chart’: ‘lang_model1’, ‘sanitization’: ‘lang_model1’, ‘summary_generation’: ‘lang_model1’, ‘title_generation_prompt’: ‘lang_model2’, ‘text2sql’: ‘lang_model2’, ‘agg_table’: ‘lang_model2’, ‘column_metadata’: ‘lang_model2’, ‘prompt_generator’: ‘lang_model2’}, ‘allowed_embedding_models’: [‘embedding_model1’, ‘embedding_model2’], ‘preferred_embedding_model’: ‘embedding_model1’, ‘project_name’: ‘LLM Project’, ‘created_ts’: 1675292368, ‘modified_ts’: 1675292368, ‘created_by’: ‘user1’, ‘modified_by’: ‘user1’, ‘status’: ‘run’}], ‘current_page’: 1, ‘page_size’: 100, ‘previous_page’: None, ‘next_page’: None, ‘has_previous’: False, ‘previous_items’: 0, ‘has_next’: False, ‘total’: 1, ‘pages’: 1}}
- Fields:
- field items: List[V2QNAMetadataModel] = []
QNA metadata returned by search in page.
- pydantic model V1QNAMetadataQuery
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataQuery", "type": "object", "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ] }
- Fields:
- field additional_tags: Dict = {}
Additional tags associated with metadata’s query
- field chart_type: str | None = None
Chart type.
- field complexity: str | None = ''
Query complexity. Supported values: Low, Medium, High
- field created_by: str | None = 'system'
Determines whether it’s a user or system generated query.
- field description: str | None = None
Query description.
- field is_suggested: bool | None = False
Determines if query should be among suggestes queries
- field language: str | None = 'en'
ISO language code for golden SQL query
- field natural_language_query: str [Required]
Natural language query.
- field question_type: str | None = 'dummy_question_type'
Query type
- field sql_query: str [Required]
SQL query.
- field template_name: str | None = ''
Template name
- pydantic model V1QNAMetadataSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1QNAMetadataSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "$ref": "#/$defs/V1QNAMetadataFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" }, "V1QNAMetadataFilters": { "example": { "names": [ "Example metdata" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "data": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data for this operation.", "title": "Data" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of allowed_llm types for this operation.", "title": "Allowed Llms" }, "preferred_llms": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of preferred_llm for this operation.", "title": "Preferred Llms" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of allowed_embedding_models for this operation.", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of preferred_embedding_model for this operation.", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of project_name for this operation.", "title": "Project Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Status" }, "entity_types": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Entity type of the metadata", "title": "Entity Types" }, "default_currencies": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Default currency of the metadata", "title": "Default Currencies" } }, "title": "V1QNAMetadataFilters", "type": "object" } }, "example": { "filters": { "names": [ "Example metadata metrics" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "order": [ { "direction": "DESC", "field": "name" } ], "page": 1, "page_size": 100, "search": "vianai" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘page’: 1, ‘page_size’: 100, ‘order’: [{‘field’: ‘name’, ‘direction’: ‘DESC’}], ‘search’: ‘vianai’, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example metadata metrics’]}}}
- Fields:
- field filters: V1QNAMetadataFilters [Required]
Specifies different condition(s) for filtering the results.
- pydantic model V1QNAMetadataTable
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMetadataTable", "type": "object", "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "$defs": { "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" } }, "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "required": [ "name" ] }
- Config:
from_attributes: bool = True
json_schema_extra: dict = {‘example’: {‘name’: ‘Product’, ‘columns’: [{‘data_type’: ‘bigint’, ‘description’: ‘Product Id’}], ‘rules’: ‘Prompt rules for Product’, ‘entity_metadata’: [{‘entity’: ‘product_name’, ‘entity_type’: ‘product’}]}}
- Fields:
- field columns: List[V1QNAMetadataColumn] = []
- field description: str | None = None
- field entity_metadata: list | None = []
- field foreign_keys: List[V1QNAMetadataForeignKey] | None = None
- field name: str [Required]
- field primary_key: V1QNAMetadataPrimaryKey | None = None
- field rules: str | None = None
- pydantic model V1QNAMetadataUpdates
Bases:
V1BaseQNAMetadataModel
Show JSON schema
{ "title": "V1QNAMetadataUpdates", "type": "object", "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of config", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata name", "title": "Name" }, "filters": { "$ref": "#/$defs/V1QNAMetadataFilters", "description": "Specifies different condition(s) for filtering the results." }, "data": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataData" }, { "type": "null" } ], "default": null }, "generate_alternate_queries": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Alternate Queries" }, "application_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Application type", "title": "Application Type" }, "qnametadata_index": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Qnametadata Index" }, "entity_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Entity type of the metadata", "title": "Entity Type" }, "default_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Default currency of the metadata", "title": "Default Currency" }, "company_metadata": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataCompanyMetadata" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Company Metadata" } }, "$defs": { "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataCompanyMetadata": { "properties": { "parent_company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Parent Company Name" }, "company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Name" }, "company_code": { "title": "Company Code", "type": "string" }, "company_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Country" }, "company_currency": { "title": "Company Currency", "type": "string" }, "global_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Global Currency" } }, "required": [ "company_code", "company_currency" ], "title": "V1QNAMetadataCompanyMetadata", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataFilters": { "example": { "names": [ "Example metdata" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of metadata names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "data": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data for this operation.", "title": "Data" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of allowed_llm types for this operation.", "title": "Allowed Llms" }, "preferred_llms": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of preferred_llm for this operation.", "title": "Preferred Llms" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of allowed_embedding_models for this operation.", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of preferred_embedding_model for this operation.", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of project_name for this operation.", "title": "Project Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Status" }, "entity_types": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Entity type of the metadata", "title": "Entity Types" }, "default_currencies": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Default currency of the metadata", "title": "Default Currencies" } }, "title": "V1QNAMetadataFilters", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "example": { "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": [ { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" } ], "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": [ { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" } ], "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Updated metadata description", "filters": { "names": [ "Example metadata" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "generate_alternate_queries": false, "name": "Updated metadata name" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘name’: ‘Updated metadata name’, ‘description’: ‘Updated metadata description’, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example metadata’]}, ‘data’: {‘connection_name’: ‘sample_ext_connection’, ‘tables’: [{‘name’: ‘Table 1’, ‘description’: ‘Sample Table 1’, ‘columns’: [{‘name’: ‘Col1’, ‘data_type’: ‘string’, ‘description’: ‘’, ‘aliases’: [‘string_alias1’, ‘string_alias2’], ‘categorical’: True, ‘sample_values’: [‘sdasd’, ‘vdsvd’]}, {‘name’: ‘Col2’, ‘data_type’: ‘datetime’, ‘description’: ‘’, ‘aliases’: [‘datetime_alias1’, ‘datetime_alias2’], ‘categorical’: False, ‘sample_values’: [‘10/10/1900’]}, {‘name’: ‘Col3’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: False, ‘sample_values’: [1, 3, 4]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col1’, ‘Col2’]}, ‘foreign_keys’: [{‘name’: ‘fk_1’, ‘column_names’: [‘Col3’], ‘reference_table’: ‘Table 2’, ‘reference_column_names’: [‘Col2T2’]}], ‘rules’: ‘’}, {‘name’: ‘Table 2’, ‘description’: ‘Sample Table 2’, ‘columns’: [{‘name’: ‘Col2T2’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: True, ‘sample_values’: [1, 2, 3]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col2T2’]}, ‘foreign_keys’: [{‘name’: ‘fk_1’, ‘column_names’: [‘Col2T2’], ‘reference_table’: ‘Table 1’, ‘reference_column_names’: [‘Col3’]}], ‘rules’: ‘’}], ‘queries’: [{‘natural_language_query’: ‘give me all the cost of goods sold transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR=’0L’”, ‘description’: None}, {‘natural_language_query’: ‘Give me all the travel expense transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR=’0L’”, ‘description’: None}], ‘rules’: ‘n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.n * If years or months are not mentioned then group by DATES for cost related queries.n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.n * Always group by months if the query asks for data for any year.n ‘}, ‘generate_alternate_queries’: False}}
- Fields:
- field application_type: str | None = None
Application type
- field company_metadata: List[V1QNAMetadataCompanyMetadata] | None = None
- field config: dict | None = None
Dict of config
- field data: V1QNAMetadataData | None = None
- field default_currency: str | None = None
Default currency of the metadata
- field description: str | None = None
metadata description
- field entity_type: str | None = None
Entity type of the metadata
- field filters: V1QNAMetadataFilters [Required]
Specifies different condition(s) for filtering the results.
- field generate_alternate_queries: bool | None = False
- field name: str | None = None
metadata name
- field qnametadata_index: str | None = None
- pydantic model V1QNAMigrateDBRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMigrateDBRequest", "type": "object", "properties": { "qna_metadata_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Qna metadata name", "title": "Qna Metadata Name" }, "destination_db": { "maxLength": 128, "title": "Destination Db", "type": "string" }, "hcf_version": { "maxLength": 10, "title": "Hcf Version", "type": "string" } }, "required": [ "destination_db", "hcf_version" ] }
- field destination_db: str [Required]
- Constraints:
max_length = 128
- field hcf_version: str [Required]
- Constraints:
max_length = 10
- field qna_metadata_name: str | None = None
Qna metadata name
- pydantic model V1QNAMigrateDBResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNAMigrateDBResponse", "type": "object", "properties": { "status": { "title": "Status", "type": "string" }, "message": { "title": "Message", "type": "string" } }, "required": [ "status", "message" ] }
- Fields:
- field message: str [Required]
- field status: str [Required]
- pydantic model V1QNASuggestedQuestion
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNASuggestedQuestion", "type": "object", "properties": { "query": { "title": "Query", "type": "string" } }, "required": [ "query" ] }
- Fields:
- field query: str [Required]
- pydantic model V1QNASuggestedQuestionRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNASuggestedQuestionRequest", "type": "object", "properties": { "query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Query" }, "qna_metadata_name": { "title": "Qna Metadata Name", "type": "string" }, "size": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 10, "description": "Number of suggested questions", "title": "Size" } }, "required": [ "qna_metadata_name" ] }
- field qna_metadata_name: str [Required]
- field query: str | None = None
- field size: int | None = 10
Number of suggested questions
- pydantic model V1QNASuggestedQuestionResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNASuggestedQuestionResponse", "type": "object", "properties": { "results": { "items": { "$ref": "#/$defs/V1QNASuggestedQuestion" }, "title": "Results", "type": "array" } }, "$defs": { "V1QNASuggestedQuestion": { "properties": { "query": { "title": "Query", "type": "string" } }, "required": [ "query" ], "title": "V1QNASuggestedQuestion", "type": "object" } }, "required": [ "results" ] }
- field results: List[V1QNASuggestedQuestion] [Required]
- pydantic model V1QNASummaryGenerationRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNASummaryGenerationRequest", "type": "object", "properties": { "qna_metadata_name": { "title": "Qna Metadata Name", "type": "string" }, "query": { "title": "Query", "type": "string" }, "sql": { "title": "Sql", "type": "string" }, "data": { "title": "Data", "type": "object" } }, "required": [ "qna_metadata_name", "query", "sql", "data" ] }
- field data: dict [Required]
- field qna_metadata_name: str [Required]
- field query: str [Required]
- field sql: str [Required]
- pydantic model V1QNASummaryGenerationResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QNASummaryGenerationResponse", "type": "object", "properties": {} }
- pydantic model V1SQLGPTRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1SQLGPTRequest", "type": "object", "properties": { "prompt": { "anyOf": [ { "type": "object" }, { "type": "string" } ], "description": "prompt to llm", "title": "Prompt" }, "qna_metadata_name": { "description": "name of qna metadata", "title": "Qna Metadata Name", "type": "string" }, "query": { "description": "query asked by user", "title": "Query", "type": "string" }, "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Unique identifier generated by platform for the alert.", "title": "Uuid" }, "transaction_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Transaction id", "title": "Transaction Id" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Thread uuid", "title": "Qna Thread Uuid" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of sources", "title": "Sources" }, "fewshot": { "anyOf": [ { "items": { "$ref": "#/$defs/V1ChartFewshotItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "golden sql examples given to the model", "title": "Fewshot" }, "process_state": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "Process state of the qna io", "title": "Process State" } }, "$defs": { "V1ChartFewshotItem": { "properties": { "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "chart type", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "created by", "title": "Created By" }, "query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql query", "title": "Query" }, "similarity_score": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "similarity score", "title": "Similarity Score" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "golden sql response", "title": "Sql Query" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of template", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "type of question", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "complexity of query", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "is a suggested query", "title": "Is Suggested" } }, "title": "V1ChartFewshotItem", "type": "object" } }, "required": [ "prompt", "qna_metadata_name", "query" ] }
- Fields:
- field fewshot: List[V1ChartFewshotItem] | None = None
golden sql examples given to the model
- field process_state: dict | None = {}
Process state of the qna io
- field prompt: dict | str [Required]
prompt to llm
- field qna_metadata_name: str [Required]
name of qna metadata
- field qna_thread_uuid: str | None = None
Thread uuid
- field query: str [Required]
query asked by user
- field sources: List[str] | None = None
list of sources
- field transaction_id: str | None = None
Transaction id
- field uuid: str | None = None
Unique identifier generated by platform for the alert.
- pydantic model V1SQLGPTResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1SQLGPTResponse", "type": "object", "properties": { "generate_sql": { "anyOf": [ { "type": "string" }, { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "description": "generated sql", "title": "Generate Sql" }, "dataframe": { "anyOf": [ { "type": "object" }, { "type": "string" }, { "type": "null" } ], "default": null, "description": "dataframe", "title": "Dataframe" }, "sql_explanation": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "generated sql explanation", "title": "Sql Explanation" }, "confidence_level": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "confidence level", "title": "Confidence Level" }, "column_metadata": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "column metadata information", "title": "Column Metadata" }, "agg_dataframe": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "aggregate dataframe", "title": "Agg Dataframe" } } }
- Fields:
- field agg_dataframe: dict | None = None
aggregate dataframe
- field column_metadata: dict | None = None
column metadata information
- field confidence_level: str | None = None
confidence level
- field dataframe: dict | str | None = None
dataframe
- field generate_sql: str | tuple | None = None
generated sql
- field sql_explanation: str | None = None
generated sql explanation
- pydantic model V2QNAMetadataModel
Bases:
V1QNAMetadataModel
Show JSON schema
{ "title": "V2QNAMetadataModel", "type": "object", "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "metadata description", "title": "Description" }, "allowed_llms": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "LLMs allowed for use", "title": "Allowed Llms" }, "preferred_llm": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "preferred LLM", "title": "Preferred Llm" }, "allowed_embedding_models": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Embedding Models allowed for use", "title": "Allowed Embedding Models" }, "preferred_embedding_model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "preferred Embedding Model", "title": "Preferred Embedding Model" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Project name", "title": "Project Name" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who created the metadata", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the metadata", "title": "Modified By" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Status of the metadata", "title": "Status" }, "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Version of the metadata", "title": "Version" }, "config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Dict of config", "title": "Config" }, "external_connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "External connection name", "title": "External Connection Name" }, "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the metadata.", "title": "Uuid" }, "qnametadata_index": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Index name of the metadata.", "title": "Qnametadata Index" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "data": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataData" }, { "type": "null" } ], "default": null }, "job_status": { "anyOf": [ { "$ref": "#/$defs/V1AutoGenModel" }, { "type": "null" } ], "default": null }, "generate_alternate_queries": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Alternate Queries" }, "generate_golden_sql": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Generate Golden Sql" }, "entity_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "single", "description": "Entity type of the metadata", "title": "Entity Type" }, "default_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Default currency of the metadata", "title": "Default Currency" }, "company_metadata": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataCompanyMetadata" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Company Metadata" } }, "$defs": { "V1AutoGenModel": { "properties": { "job_id": { "title": "Job Id", "type": "string" }, "job_type": { "title": "Job Type", "type": "string" }, "job_description": { "default": null, "title": "Job Description", "type": "string" }, "user_id": { "title": "User Id", "type": "string" }, "status": { "title": "Status", "type": "string" }, "statusdetails": { "title": "Statusdetails", "type": "string" }, "result": { "title": "Result", "type": "string" }, "exception": { "title": "Exception", "type": "string" }, "created": { "title": "Created", "type": "string" }, "started": { "title": "Started", "type": "string" }, "finished": { "title": "Finished", "type": "string" }, "timestamp": { "title": "Timestamp", "type": "number" }, "configmap": { "title": "Configmap", "type": "string" } }, "required": [ "job_id", "job_type", "user_id", "status", "statusdetails", "result", "exception", "created", "started", "finished", "timestamp", "configmap" ], "title": "V1AutoGenModel", "type": "object" }, "V1QNAMetadataColumn": { "example": { "categorical": false, "data_type": "bigint", "description": "Product Id", "name": "ProductId" }, "properties": { "name": { "title": "Name", "type": "string" }, "data_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Data Type" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "aliases": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Aliases" }, "categorical": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Categorical" }, "sample_values": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": null, "title": "Sample Values" } }, "required": [ "name" ], "title": "V1QNAMetadataColumn", "type": "object" }, "V1QNAMetadataCompanyMetadata": { "properties": { "parent_company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Parent Company Name" }, "company_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Name" }, "company_code": { "title": "Company Code", "type": "string" }, "company_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Company Country" }, "company_currency": { "title": "Company Currency", "type": "string" }, "global_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Global Currency" } }, "required": [ "company_code", "company_currency" ], "title": "V1QNAMetadataCompanyMetadata", "type": "object" }, "V1QNAMetadataData": { "properties": { "connection_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Connection Name" }, "tables": { "items": { "$ref": "#/$defs/V1QNAMetadataTable" }, "title": "Tables", "type": "array" }, "queries": { "items": { "$ref": "#/$defs/V1QNAMetadataQuery" }, "title": "Queries", "type": "array" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "use_intent_classification": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "title": "Use Intent Classification" }, "max_retry_attempts": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "title": "Max Retry Attempts" }, "user_top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "User Top Match Similarity Threshold" }, "sql_match_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Sql Match Threshold" }, "top_match_similarity_threshold": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "title": "Top Match Similarity Threshold" } }, "required": [ "tables", "queries" ], "title": "V1QNAMetadataData", "type": "object" }, "V1QNAMetadataForeignKey": { "properties": { "name": { "title": "Name", "type": "string" }, "column_names": { "items": { "type": "string" }, "title": "Column Names", "type": "array" }, "reference_table": { "title": "Reference Table", "type": "string" }, "reference_column_names": { "items": { "type": "string" }, "title": "Reference Column Names", "type": "array" } }, "required": [ "name", "column_names", "reference_table", "reference_column_names" ], "title": "V1QNAMetadataForeignKey", "type": "object" }, "V1QNAMetadataPrimaryKey": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Name" }, "column_names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Column Names" } }, "title": "V1QNAMetadataPrimaryKey", "type": "object" }, "V1QNAMetadataQuery": { "properties": { "natural_language_query": { "description": "Natural language query.", "title": "Natural Language Query", "type": "string" }, "sql_query": { "description": "SQL query.", "title": "Sql Query", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Query description.", "title": "Description" }, "chart_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Chart type.", "title": "Chart Type" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "system", "description": "Determines whether it's a user or system generated query.", "title": "Created By" }, "template_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Template name", "title": "Template Name" }, "question_type": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "dummy_question_type", "description": "Query type", "title": "Question Type" }, "complexity": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "", "description": "Query complexity. Supported values: `Low`, `Medium`, `High`", "title": "Complexity" }, "is_suggested": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Determines if query should be among suggestes queries", "title": "Is Suggested" }, "language": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "en", "description": "ISO language code for golden SQL query", "title": "Language" }, "additional_tags": { "default": {}, "description": "Additional tags associated with metadata's query", "title": "Additional Tags", "type": "object" } }, "required": [ "natural_language_query", "sql_query" ], "title": "V1QNAMetadataQuery", "type": "object" }, "V1QNAMetadataTable": { "example": { "columns": [ { "data_type": "bigint", "description": "Product Id" } ], "entity_metadata": [ { "entity": "product_name", "entity_type": "product" } ], "name": "Product", "rules": "Prompt rules for Product" }, "properties": { "name": { "title": "Name", "type": "string" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Description" }, "columns": { "default": [], "items": { "$ref": "#/$defs/V1QNAMetadataColumn" }, "title": "Columns", "type": "array" }, "primary_key": { "anyOf": [ { "$ref": "#/$defs/V1QNAMetadataPrimaryKey" }, { "type": "null" } ], "default": null }, "foreign_keys": { "anyOf": [ { "items": { "$ref": "#/$defs/V1QNAMetadataForeignKey" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Foreign Keys" }, "rules": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Rules" }, "entity_metadata": { "anyOf": [ { "items": {}, "type": "array" }, { "type": "null" } ], "default": [], "title": "Entity Metadata" } }, "required": [ "name" ], "title": "V1QNAMetadataTable", "type": "object" } }, "example": { "allowed_embedding_models": [ "embedding_model1", "embedding_model2" ], "allowed_llms": [ "lang_model1", "lang_model2" ], "data": { "connection_name": "sample_ext_connection", "queries": [ { "description": null, "natural_language_query": "give me all the cost of goods sold transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR='0L'" }, { "description": null, "natural_language_query": "Give me all the travel expense transactions?", "sql_query": "SELECT KSL,TO_DATE(BUDAT,'YYYYMMDD') as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR='0L'" } ], "rules": "\n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.\n * If years or months are not mentioned then group by DATES for cost related queries.\n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.\n * Always group by months if the query asks for data for any year.\n ", "tables": [ { "columns": [ { "aliases": [ "string_alias1", "string_alias2" ], "categorical": true, "data_type": "string", "description": "", "name": "Col1", "sample_values": [ "sdasd", "vdsvd" ] }, { "aliases": [ "datetime_alias1", "datetime_alias2" ], "categorical": false, "data_type": "datetime", "description": "", "name": "Col2", "sample_values": [ "10/10/1900" ] }, { "aliases": [ "int_alias1", "int_alias2" ], "categorical": false, "data_type": "int", "description": "", "name": "Col3", "sample_values": [ 1, 3, 4 ] } ], "description": "Sample Table 1", "foreign_keys": { "column_names": [ "Col3" ], "name": "fk_1", "reference_column_names": [ "Col2T2" ], "reference_table": "Table 2" }, "name": "Table 1", "primary_key": { "column_names": [ "Col1", "Col2" ], "name": "pk_1" }, "rules": "" }, { "columns": [ { "aliases": [ "int_alias1", "int_alias2" ], "categorical": true, "data_type": "int", "description": "", "name": "Col2T2", "sample_values": [ 1, 2, 3 ] } ], "description": "Sample Table 2", "foreign_keys": { "column_names": [ "Col2T2" ], "name": "fk_1", "reference_column_names": [ "Col3" ], "reference_table": "Table 1" }, "name": "Table 2", "primary_key": { "column_names": [ "Col2T2" ], "name": "pk_1" }, "rules": "" } ] }, "description": "Sample for metadata", "entity_type": "single", "job_status": { "configmap": "config-autogen-queue-30202017278035", "created": "2023-10-30 20:20:17.295084", "exception": "", "finished": "", "job_description": null, "job_id": "autogen-queue-30202017278035", "job_type": "autogen", "result": "", "started": "", "status": "queued", "statusdetails": "", "timestamp": 1698697217295.0898, "user_id": "vianai" }, "name": "sample_metadata", "preferred_embedding_model": "embedding_model1", "preferred_llm": { "agg_chart": "lang_model1", "agg_table": "lang_model2", "chart": "lang_model1", "column_metadata": "lang_model2", "prompt_generator": "lang_model2", "sanitization": "lang_model1", "summarization": "lang_model1", "summary_generation": "lang_model1", "text2sql": "lang_model2", "title_generation_prompt": "lang_model2" }, "project_name": "LLM Project" } }
- Config:
from_attributes: bool = True
json_schema_extra: dict = {‘example’: {‘description’: ‘Sample for metadata’, ‘allowed_llms’: [‘lang_model1’, ‘lang_model2’], ‘preferred_llm’: {‘summarization’: ‘lang_model1’, ‘chart’: ‘lang_model1’, ‘agg_chart’: ‘lang_model1’, ‘sanitization’: ‘lang_model1’, ‘summary_generation’: ‘lang_model1’, ‘title_generation_prompt’: ‘lang_model2’, ‘text2sql’: ‘lang_model2’, ‘agg_table’: ‘lang_model2’, ‘column_metadata’: ‘lang_model2’, ‘prompt_generator’: ‘lang_model2’}, ‘allowed_embedding_models’: [‘embedding_model1’, ‘embedding_model2’], ‘preferred_embedding_model’: ‘embedding_model1’, ‘project_name’: ‘LLM Project’, ‘name’: ‘sample_metadata’, ‘entity_type’: ‘single’, ‘data’: {‘connection_name’: ‘sample_ext_connection’, ‘tables’: [{‘name’: ‘Table 1’, ‘description’: ‘Sample Table 1’, ‘columns’: [{‘name’: ‘Col1’, ‘data_type’: ‘string’, ‘description’: ‘’, ‘aliases’: [‘string_alias1’, ‘string_alias2’], ‘categorical’: True, ‘sample_values’: [‘sdasd’, ‘vdsvd’]}, {‘name’: ‘Col2’, ‘data_type’: ‘datetime’, ‘description’: ‘’, ‘aliases’: [‘datetime_alias1’, ‘datetime_alias2’], ‘categorical’: False, ‘sample_values’: [‘10/10/1900’]}, {‘name’: ‘Col3’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: False, ‘sample_values’: [1, 3, 4]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col1’, ‘Col2’]}, ‘foreign_keys’: {‘name’: ‘fk_1’, ‘column_names’: [‘Col3’], ‘reference_table’: ‘Table 2’, ‘reference_column_names’: [‘Col2T2’]}, ‘rules’: ‘’}, {‘name’: ‘Table 2’, ‘description’: ‘Sample Table 2’, ‘columns’: [{‘name’: ‘Col2T2’, ‘data_type’: ‘int’, ‘description’: ‘’, ‘aliases’: [‘int_alias1’, ‘int_alias2’], ‘categorical’: True, ‘sample_values’: [1, 2, 3]}], ‘primary_key’: {‘name’: ‘pk_1’, ‘column_names’: [‘Col2T2’]}, ‘foreign_keys’: {‘name’: ‘fk_1’, ‘column_names’: [‘Col2T2’], ‘reference_table’: ‘Table 1’, ‘reference_column_names’: [‘Col3’]}, ‘rules’: ‘’}], ‘queries’: [{‘natural_language_query’: ‘give me all the cost of goods sold transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE FROM ACDOCA WHERE RACCT=0050300000 AND RLDNR=’0L’”, ‘description’: None}, {‘natural_language_query’: ‘Give me all the travel expense transactions?’, ‘sql_query’: “SELECT KSL,TO_DATE(BUDAT,’YYYYMMDD’) as DATE, RLDNR, RACCT FROM ACDOCA WHERE RACCT=61007000 AND RLDNR=’0L’”, ‘description’: None}], ‘rules’: ‘n * If months or years is mentioned in the query, return them in the sql response too. use MONTHS and YEARS as names.n * If years or months are not mentioned then group by DATES for cost related queries.n * Always EXPLICITLY mention the columns in the SELECT clause. Do not use SELECT *. If asked for all the columns do select on all the columns.n * Always group by months if the query asks for data for any year.n ‘}, ‘job_status’: {‘job_id’: ‘autogen-queue-30202017278035’, ‘job_type’: ‘autogen’, ‘job_description’: None, ‘user_id’: ‘vianai’, ‘status’: ‘queued’, ‘statusdetails’: ‘’, ‘result’: ‘’, ‘exception’: ‘’, ‘created’: ‘2023-10-30 20:20:17.295084’, ‘started’: ‘’, ‘finished’: ‘’, ‘timestamp’: 1698697217295.0898, ‘configmap’: ‘config-autogen-queue-30202017278035’}}}
- Fields:
- field company_metadata: List[V1QNAMetadataCompanyMetadata] | None = None
- field data: V1QNAMetadataData | None = None
- field default_currency: str | None = ''
Default currency of the metadata
- field entity_type: str | None = 'single'
Entity type of the metadata
- field name: str | None = None
vianops_client.models.qnastore.qna_orchestrator module
- pydantic model V1OrchestratorChart
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorChart", "type": "object", "properties": { "chart_type": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Type of chart", "title": "Chart Type" }, "labels": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of chart labels", "title": "Labels" }, "datasets": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorDatasetsItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of chart datasets", "title": "Datasets" } }, "$defs": { "V1OrchestratorDatagroupsItem": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the data group", "title": "Name" }, "desc": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the data group", "title": "Desc" }, "data": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data points", "title": "Data" } }, "title": "V1OrchestratorDatagroupsItem", "type": "object" }, "V1OrchestratorDatasetsItem": { "properties": { "metric": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Metric description", "title": "Metric" }, "datagroups": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorDatagroupsItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data groups", "title": "Datagroups" } }, "title": "V1OrchestratorDatasetsItem", "type": "object" } } }
- Fields:
- field chart_type: int | None = None
Type of chart
- field datasets: List[V1OrchestratorDatasetsItem] | None = None
List of chart datasets
- field labels: List[int] | None = None
List of chart labels
- pydantic model V1OrchestratorDatagroupsItem
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorDatagroupsItem", "type": "object", "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the data group", "title": "Name" }, "desc": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the data group", "title": "Desc" }, "data": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data points", "title": "Data" } } }
- field data: List[int] | None = None
List of data points
- field desc: str | None = None
Description of the data group
- field name: str | None = None
Name of the data group
- pydantic model V1OrchestratorDatasetsItem
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorDatasetsItem", "type": "object", "properties": { "metric": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Metric description", "title": "Metric" }, "datagroups": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorDatagroupsItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data groups", "title": "Datagroups" } }, "$defs": { "V1OrchestratorDatagroupsItem": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the data group", "title": "Name" }, "desc": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Description of the data group", "title": "Desc" }, "data": { "anyOf": [ { "items": { "type": "integer" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data points", "title": "Data" } }, "title": "V1OrchestratorDatagroupsItem", "type": "object" } } }
- Fields:
- field datagroups: List[V1OrchestratorDatagroupsItem] | None = None
List of data groups
- field metric: str | None = None
Metric description
- pydantic model V1OrchestratorExtrasItem
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorExtrasItem", "type": "object", "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the extra item", "title": "Name" }, "content": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorQuerySummary" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query summaries for this extra", "title": "Content" } }, "$defs": { "V1OrchestratorQuerySummary": { "properties": { "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Title of the query summary", "title": "Title" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the query", "title": "Summary" } }, "title": "V1OrchestratorQuerySummary", "type": "object" } } }
- Fields:
- field content: List[V1OrchestratorQuerySummary] | None = None
List of query summaries for this extra
- field name: str | None = None
Name of the extra item
- pydantic model V1OrchestratorJargon
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorJargon", "type": "object", "properties": { "qnaio_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA IO uuid.", "title": "Qnaio Uuid" }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "I have interpreted message", "title": "Message" }, "jargon_metadata": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "jargon metadata", "title": "Jargon Metadata" } } }
- field jargon_metadata: dict | None = None
jargon metadata
- field message: str | None = None
I have interpreted message
- field qnaio_uuid: str | None = None
QNA IO uuid.
- pydantic model V1OrchestratorQuerySummary
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorQuerySummary", "type": "object", "properties": { "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Title of the query summary", "title": "Title" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the query", "title": "Summary" } } }
- field summary: str | None = None
Summary of the query
- field title: str | None = None
Title of the query summary
- pydantic model V1OrchestratorRequest
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorRequest", "type": "object", "properties": { "request_body": { "$ref": "#/$defs/V1PromptGenerationModel", "description": "Prompt generation model." }, "qnaio_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA IO uuid.", "title": "Qnaio Uuid" }, "thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Thread uuid.", "title": "Thread Uuid" }, "conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Conversation uuid.", "title": "Conversation Uuid" }, "thread_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "New Thread", "description": "Thread name.", "title": "Thread Name" }, "conversation_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "New Conversation", "description": "Conversation name.", "title": "Conversation Name" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of sources.", "title": "Sources" }, "request_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Request Id", "title": "Request Id" }, "flag_fuzzy": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": true, "description": "Fuzzy flag", "title": "Flag Fuzzy" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": false, "description": "Follow-up flag", "title": "Flag Followup" } }, "$defs": { "V1PromptGenerationModel": { "properties": { "query": { "anyOf": [ { "type": "string" }, { "type": "object" }, { "items": {}, "type": "array" } ], "title": "Query" }, "qna_metadata_name": { "title": "Qna Metadata Name", "type": "string" }, "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Uuid" } }, "required": [ "query", "qna_metadata_name" ], "title": "V1PromptGenerationModel", "type": "object" } }, "required": [ "request_body" ] }
- field conversation_name: str | None = 'New Conversation'
Conversation name.
- field conversation_uuid: str | None = None
Conversation uuid.
- field flag_followup: bool | None = False
Follow-up flag
- field flag_fuzzy: bool | None = True
Fuzzy flag
- field qnaio_uuid: str | None = None
QNA IO uuid.
- field request_body: V1PromptGenerationModel [Required]
Prompt generation model.
- field request_id: str | None = None
Request Id
- field sources: List[str] | None = None
List of sources.
- field thread_name: str | None = 'New Thread'
Thread name.
- field thread_uuid: str | None = None
Thread uuid.
- pydantic model V1OrchestratorResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1OrchestratorResponse", "type": "object", "properties": { "success": { "anyOf": [ { "type": "boolean" }, { "type": "string" } ], "description": "success status", "title": "Success" }, "Source": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source information", "title": "Source" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source information", "title": "Metadata Uuid" }, "answer": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of answers", "title": "Answer" }, "column_metadata": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "column metadata", "title": "Column Metadata" }, "jargon_metadata": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "column metadata", "title": "Jargon Metadata" }, "data_types": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "data types", "title": "Data Types" }, "dataframe": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of dataframes", "title": "Dataframe" }, "chart": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "chart information", "title": "Chart" }, "agg_dataframe": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Agg dataframe", "title": "Agg Dataframe" }, "agg_chart": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "Agg chart object", "title": "Agg Chart" }, "extras": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorExtrasItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of extra items", "title": "Extras" }, "qnaio_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qnaio", "title": "Qnaio Uuid" }, "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "title of data", "title": "Title" }, "generated_sql_ts": { "anyOf": [ { "type": "string" }, { "type": "number" }, { "type": "null" } ], "default": null, "description": "generated sql", "title": "Generated Sql Ts" }, "promoted_match": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "if the user's query matches a promoted query", "title": "Promoted Match" }, "user_promoted": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "if this query was promoted by the user", "title": "User Promoted" }, "transaction_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "transaction ID", "title": "Transaction Id" }, "request_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "request ID", "title": "Request Id" }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "error message", "title": "Error" }, "metadata": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "qna metadata information", "title": "Metadata" }, "process_state": { "default": {}, "description": "Websocket messages", "title": "Process State", "type": "object" }, "context_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Full-fledged contextual question", "title": "Context Query" }, "question_identifier": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "question identifier", "title": "Question Identifier" }, "fuzzy_match_metadata": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "typo identifier", "title": "Fuzzy Match Metadata" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA conversation uuid", "title": "Qna Conversation Uuid" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA thread uuid", "title": "Qna Thread Uuid" }, "sql_interpretation_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "SQL assumption", "title": "Sql Interpretation Message" }, "sql_explanation": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "sql explain", "title": "Sql Explanation" } }, "$defs": { "V1OrchestratorExtrasItem": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the extra item", "title": "Name" }, "content": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorQuerySummary" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query summaries for this extra", "title": "Content" } }, "title": "V1OrchestratorExtrasItem", "type": "object" }, "V1OrchestratorQuerySummary": { "properties": { "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Title of the query summary", "title": "Title" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the query", "title": "Summary" } }, "title": "V1OrchestratorQuerySummary", "type": "object" } }, "required": [ "success" ] }
- Fields:
- field Source: str | None = None
source information
- field agg_chart: dict | None = None
Agg chart object
- field agg_dataframe: List[dict] | None = None
Agg dataframe
- field answer: List[str] | None = None
list of answers
- field chart: dict | None = None
chart information
- field column_metadata: dict | None = None
column metadata
- field context_query: str | None = None
Full-fledged contextual question
- field data_types: dict | None = None
data types
- field dataframe: List[dict] | None = None
list of dataframes
- field error: str | None = None
error message
- field extras: List[V1OrchestratorExtrasItem] | None = None
list of extra items
- field fuzzy_match_metadata: str | None = None
typo identifier
- field generated_sql_ts: str | float | None = None
generated sql
- field jargon_metadata: dict | None = None
column metadata
- field metadata: List[dict] | None = []
qna metadata information
- field metadata_uuid: str | None = None
source information
- field process_state: dict = {}
Websocket messages
- field promoted_match: bool | None = None
if the user’s query matches a promoted query
- field qna_conversation_uuid: str | None = None
QNA conversation uuid
- field qna_thread_uuid: str | None = None
QNA thread uuid
- field qnaio_uuid: str | None = None
uuid of qnaio
- field question_identifier: str | None = None
question identifier
- field request_id: str | None = None
request ID
- field sql_explanation: str | None = None
sql explain
- field sql_interpretation_message: str | None = None
SQL assumption
- field success: bool | str [Required]
success status
- field title: str | None = None
title of data
- field transaction_id: str | None = None
transaction ID
- field user_promoted: bool | None = None
if this query was promoted by the user
vianops_client.models.qnastore.qna_rag module
- pydantic model V1QnaRag
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaRag", "type": "object", "properties": { "model_name": { "description": "name of model", "title": "Model Name", "type": "string" }, "project_name": { "default": "QNA Project", "description": "name of project", "title": "Project Name", "type": "string" }, "qna_metadata_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of metadata", "title": "Qna Metadata Name" }, "qna_conversation_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of conversation", "title": "Qna Conversation Name" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of conversation", "title": "Qna Conversation Uuid" }, "qna_thread_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of thread", "title": "Qna Thread Name" }, "qna_thread_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of thread", "title": "Qna Thread Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of io entry", "title": "Qna Io Uuid" }, "qna_io_config": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "io config", "title": "Qna Io Config" }, "query": { "description": "query given by user", "title": "Query", "type": "string" }, "docs_selected": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "text documents selected", "title": "Docs Selected" }, "source": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source of query (user information)", "title": "Source" }, "user": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "username of user", "title": "User" }, "flag_followup": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag for followup", "title": "Flag Followup" } }, "additionalProperties": true, "required": [ "model_name", "query" ] }
- Config:
protected_namespaces: tuple = ()
extra: str = allow
- Fields:
- field docs_selected: List[str] | None = None
text documents selected
- field flag_followup: bool | None = None
flag for followup
- field model_name: str [Required]
name of model
- field project_name: str = 'QNA Project'
name of project
- field qna_conversation_name: str | None = None
name of conversation
- field qna_conversation_uuid: str | None = None
uuid of conversation
- field qna_io_config: dict | None = {}
io config
- field qna_io_uuid: str | None = None
uuid of io entry
- field qna_metadata_name: str | None = None
name of metadata
- field qna_thread_name: str | None = None
name of thread
- field qna_thread_uuid: str | None = None
uuid of thread
- field query: str [Required]
query given by user
- field source: str | None = None
source of query (user information)
- field user: str | None = None
username of user
- pydantic model V1QnaRagGetResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1QnaRagGetResponseList", "type": "array", "$defs": { "V1QnaRagGetResponse": { "properties": { "model_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of model", "title": "Model Name" }, "project_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "name of project", "title": "Project Name" } }, "title": "V1QnaRagGetResponse", "type": "object" } }, "items": { "$ref": "#/$defs/V1QnaRagGetResponse" } }
- field root: List[V1QnaRagGetResponse] [Required]
- pydantic model V1QnaRagResponse
Bases:
BaseModel
Show JSON schema
{ "title": "V1QnaRagResponse", "type": "object", "properties": { "success": { "description": "status of response", "title": "Success", "type": "boolean" }, "qnaio_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qnaio", "title": "Qnaio Uuid" }, "Source": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source information", "title": "Source" }, "metadata_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "source metadata uuid ", "title": "Metadata Uuid" }, "answer": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of answers", "title": "Answer" }, "column_metadata": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "column metadata", "title": "Column Metadata" }, "data_types": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "data types", "title": "Data Types" }, "dataframe": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of dataframes", "title": "Dataframe" }, "chart": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "chart information", "title": "Chart" }, "agg_dataframe": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of dataframes", "title": "Agg Dataframe" }, "agg_chart": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": null, "description": "agg chart information", "title": "Agg Chart" }, "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "title of data", "title": "Title" }, "extras": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorExtrasItem" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of extra items", "title": "Extras" }, "generated_sql_ts": { "anyOf": [ { "type": "string" }, { "type": "number" }, { "type": "null" } ], "default": null, "description": "generated SQL timestamp", "title": "Generated Sql Ts" }, "promoted_match": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "if the user's query matches a promoted query", "title": "Promoted Match" }, "user_promoted": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "if this query was promoted by the user", "title": "User Promoted" }, "transaction_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "transaction ID", "title": "Transaction Id" }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "error message", "title": "Error" }, "metadata": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "qna metadata information", "title": "Metadata" }, "result": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "response and context for prompt", "title": "Result" }, "additional_docs": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "additional documents", "title": "Additional Docs" }, "no_docs_message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "no documents message", "title": "No Docs Message" }, "docs_input": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "list of input documents", "title": "Docs Input" }, "process_state": { "default": {}, "description": "pipeline steps", "title": "Process State", "type": "object" } }, "$defs": { "V1OrchestratorExtrasItem": { "properties": { "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Name of the extra item", "title": "Name" }, "content": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrchestratorQuerySummary" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of query summaries for this extra", "title": "Content" } }, "title": "V1OrchestratorExtrasItem", "type": "object" }, "V1OrchestratorQuerySummary": { "properties": { "title": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Title of the query summary", "title": "Title" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Summary of the query", "title": "Summary" } }, "title": "V1OrchestratorQuerySummary", "type": "object" } }, "additionalProperties": true, "required": [ "success" ] }
- Config:
extra: str = allow
- Fields:
- field Source: str | None = None
source information
- field additional_docs: List[dict] | None = None
additional documents
- field agg_chart: dict | None = None
agg chart information
- field agg_dataframe: List[dict] | None = None
list of dataframes
- field answer: List[str] | None = None
list of answers
- field chart: dict | None = None
chart information
- field column_metadata: dict | None = None
column metadata
- field data_types: dict | None = None
data types
- field dataframe: List[dict] | None = None
list of dataframes
- field docs_input: List[str] | None = None
list of input documents
- field error: str | None = None
error message
- field extras: List[V1OrchestratorExtrasItem] | None = None
list of extra items
- field generated_sql_ts: str | float | None = None
generated SQL timestamp
- field metadata: List[dict] | None = None
qna metadata information
- field metadata_uuid: str | None = None
source metadata uuid
- field no_docs_message: str | None = None
no documents message
- field process_state: dict = {}
pipeline steps
- field promoted_match: bool | None = None
if the user’s query matches a promoted query
- field qnaio_uuid: str | None = None
uuid of qnaio
- field result: List[dict] | None = None
response and context for prompt
- field success: bool [Required]
status of response
- field title: str | None = None
title of data
- field transaction_id: str | None = None
transaction ID
- field user_promoted: bool | None = None
if this query was promoted by the user
vianops_client.models.qnastore.qna_report module
- pydantic model V1BaseQNAReport
Bases:
BaseModel
Show JSON schema
{ "title": "V1BaseQNAReport", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report description", "title": "Description" }, "original_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna_conversation (foreign key)", "title": "Original Conversation Uuid" }, "report_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of the conversation that generated the current report", "title": "Report Conversation Uuid" }, "layout": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "JSON field to store layout information", "title": "Layout" }, "job_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report job id", "title": "Job Id" }, "pdf_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report pdf key", "title": "Pdf Key" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna report", "title": "Status" } } }
- Fields:
- field description: str | None = None
qna report description
- field is_favorite: bool | None = None
flag to make favorite qna report
- field is_pinned: bool | None = None
flag to pin qna report
- field job_id: str | None = None
qna report job id
- field layout: dict | None = {}
JSON field to store layout information
- field name: str | None = None
qna report name
- field original_conversation_uuid: str | None = None
uuid of qna_conversation (foreign key)
- field pdf_key: str | None = None
qna report pdf key
- field report_conversation_uuid: str | None = None
uuid of the conversation that generated the current report
- field status: str | None = 'CREATED'
Status of the qna report
- field uuid: str | None = None
uuid
- pydantic model V1QNAReportFilters
Bases:
V1FiltersCommon
Show JSON schema
{ "title": "V1QNAReportFilters", "type": "object", "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna report uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna report names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "original_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List uuids of qna_conversation (foreign key)", "title": "Original Conversation Uuids" }, "report_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List uuids report conversation", "title": "Report Conversation Uuids" }, "layout": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List JSON field to store layout information", "title": "Layout" }, "job_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna report job ids", "title": "Job Ids" }, "pdf_keys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna report pdf keys", "title": "Pdf Keys" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" } }, "example": { "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
alias_generator: function = <function V1QNAReportFilters.<lambda> at 0x7f98c4d7bd80>
json_schema_extra: dict = {‘example’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’]}}
- Fields:
- field description: List[str] | None = None (alias 'descriptions')
List of descriptions for this operation.
- field is_favorite: bool | None = None
flag to make favorite qna report
- field is_pinned: bool | None = None
flag to pin qna report
- field job_id: List[str] | None = None (alias 'job_ids')
List qna report job ids
- field layout: List[dict] | None = None
List JSON field to store layout information
- field name: List[str] | None = None (alias 'names')
List of qna report names for this operation.
- field original_conversation_uuid: List[str] | None = None (alias 'original_conversation_uuids')
List uuids of qna_conversation (foreign key)
- field pdf_key: List[str] | None = None (alias 'pdf_keys')
List qna report pdf keys
- field report_conversation_uuid: List[str] | None = None (alias 'report_conversation_uuids')
List uuids report conversation
- field status: List[str] | None = None (alias 'statuses')
List of status for this operation.
- field uuid: List[str] | None = None (alias 'uuids')
List of qna report uuids for this operation.
- pydantic model V1QNAReportList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAReportList", "type": "array", "$defs": { "V1BaseQNAReport": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report description", "title": "Description" }, "original_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna_conversation (foreign key)", "title": "Original Conversation Uuid" }, "report_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of the conversation that generated the current report", "title": "Report Conversation Uuid" }, "layout": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "JSON field to store layout information", "title": "Layout" }, "job_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report job id", "title": "Job Id" }, "pdf_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report pdf key", "title": "Pdf Key" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna report", "title": "Status" } }, "title": "V1BaseQNAReport", "type": "object" } }, "items": { "$ref": "#/$defs/V1BaseQNAReport" } }
- field root: List[V1BaseQNAReport] [Required]
- pydantic model V1QNAReportPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1QNAReportPage", "type": "object", "properties": { "items": { "default": [], "description": "Job Types returned by search in page.", "items": { "$ref": "#/$defs/V1QNAReportResponse" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1QNAReportResponse": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report description", "title": "Description" }, "original_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna_conversation (foreign key)", "title": "Original Conversation Uuid" }, "report_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of the conversation that generated the current report", "title": "Report Conversation Uuid" }, "layout": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "JSON field to store layout information", "title": "Layout" }, "job_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report job id", "title": "Job Id" }, "pdf_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report pdf key", "title": "Pdf Key" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna report", "title": "Status" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Report", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Report", "title": "Modified By", "type": "string" } }, "required": [ "created_ts", "modified_ts", "created_by", "modified_by" ], "title": "V1QNAReportResponse", "type": "object" } } }
- field items: List[V1QNAReportResponse] = []
Job Types returned by search in page.
- pydantic model V1QNAReportResponse
Bases:
V1BaseQNAReport
Show JSON schema
{ "title": "V1QNAReportResponse", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report description", "title": "Description" }, "original_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna_conversation (foreign key)", "title": "Original Conversation Uuid" }, "report_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of the conversation that generated the current report", "title": "Report Conversation Uuid" }, "layout": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "JSON field to store layout information", "title": "Layout" }, "job_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report job id", "title": "Job Id" }, "pdf_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report pdf key", "title": "Pdf Key" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna report", "title": "Status" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Report", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Report", "title": "Modified By", "type": "string" } }, "required": [ "created_ts", "modified_ts", "created_by", "modified_by" ] }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field created_by: str [Required]
User that created the QNA Report
- field created_ts: datetime [Required]
Unix time in milliseconds generated at creation time.
- field modified_by: str [Required]
User who modified the QNA Report
- field modified_ts: datetime [Required]
Unix time in milliseconds generated at last modification time.
- field uuid: str | UUID | None = None
uuid
- pydantic model V1QNAReportResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAReportResponseList", "type": "array", "$defs": { "V1QNAReportResponse": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "format": "uuid", "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report description", "title": "Description" }, "original_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna_conversation (foreign key)", "title": "Original Conversation Uuid" }, "report_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of the conversation that generated the current report", "title": "Report Conversation Uuid" }, "layout": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "JSON field to store layout information", "title": "Layout" }, "job_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report job id", "title": "Job Id" }, "pdf_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report pdf key", "title": "Pdf Key" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna report", "title": "Status" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Report", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Report", "title": "Modified By", "type": "string" } }, "required": [ "created_ts", "modified_ts", "created_by", "modified_by" ], "title": "V1QNAReportResponse", "type": "object" } }, "items": { "$ref": "#/$defs/V1QNAReportResponse" } }
- field root: List[V1QNAReportResponse] [Required]
- pydantic model V1QNAReportSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1QNAReportSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "$ref": "#/$defs/V1QNAReportFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" }, "V1QNAReportFilters": { "example": { "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna report uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna report names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "original_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List uuids of qna_conversation (foreign key)", "title": "Original Conversation Uuids" }, "report_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List uuids report conversation", "title": "Report Conversation Uuids" }, "layout": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List JSON field to store layout information", "title": "Layout" }, "job_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna report job ids", "title": "Job Ids" }, "pdf_keys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna report pdf keys", "title": "Pdf Keys" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" } }, "title": "V1QNAReportFilters", "type": "object" } }, "example": { "filters": { "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "order": [ { "direction": "DESC", "field": "name" } ], "page": 1, "page_size": 100, "search": "vianai" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘page’: 1, ‘page_size’: 100, ‘order’: [{‘field’: ‘name’, ‘direction’: ‘DESC’}], ‘search’: ‘vianai’, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’]}}}
- Fields:
- field filters: V1QNAReportFilters [Required]
Specifies different condition(s) for filtering the results.
- pydantic model V1QNAReportUpdates
Bases:
V1BaseQNAReport
Show JSON schema
{ "title": "V1QNAReportUpdates", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report description", "title": "Description" }, "original_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna_conversation (foreign key)", "title": "Original Conversation Uuid" }, "report_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of the conversation that generated the current report", "title": "Report Conversation Uuid" }, "layout": { "anyOf": [ { "type": "object" }, { "type": "null" } ], "default": {}, "description": "JSON field to store layout information", "title": "Layout" }, "job_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report job id", "title": "Job Id" }, "pdf_key": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "qna report pdf key", "title": "Pdf Key" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the qna report", "title": "Status" }, "filters": { "$ref": "#/$defs/V1QNAReportFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1QNAReportFilters": { "example": { "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created Bys" }, "modified_bys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified Bys" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna report uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna report names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "original_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List uuids of qna_conversation (foreign key)", "title": "Original Conversation Uuids" }, "report_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List uuids report conversation", "title": "Report Conversation Uuids" }, "layout": { "anyOf": [ { "items": { "type": "object" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List JSON field to store layout information", "title": "Layout" }, "job_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna report job ids", "title": "Job Ids" }, "pdf_keys": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List qna report pdf keys", "title": "Pdf Keys" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin qna report", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite qna report", "title": "Is Favorite" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" } }, "title": "V1QNAReportFilters", "type": "object" } }, "example": { "filters": { "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] } }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’]}}}
- Fields:
- field filters: V1QNAReportFilters [Required]
Specifies different condition(s) for filtering the results.
vianops_client.models.qnastore.qna_text2sql module
- pydantic model V1BaseText2sql
Bases:
BaseModel
Show JSON schema
{ "title": "V1BaseText2sql", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna io (link to qna_io table)", "title": "Qna Io Uuid" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "sql query", "title": "Sql Query" }, "generated_sql": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "generated sql", "title": "Generated Sql" }, "automated_query_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of automated query id", "title": "Automated Query Ids" }, "text_answer_llm": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "LLM text answer", "title": "Text Answer Llm" }, "tables_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of tables used", "title": "Tables Used" }, "columns_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of columns used", "title": "Columns Used" }, "retry_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "description": "Integer value of retry count", "title": "Retry Count" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "status value", "title": "Status" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "vianai", "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" } } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field automated_query_ids: List[str] | None = []
List of automated query id
- field columns_used: List[str] | None = []
List of columns used
- field created_by: str | None = 'vianai'
User that created the qna io
- field generated_sql: str | None = 'n/a'
generated sql
- field modified_by: str | None = None
User that modified the qna io
- field modified_ts: datetime | None = None
Unix time in milliseconds generated at last modification time.
- field qna_io_uuid: str | None = None
uuid of qna io (link to qna_io table)
- field retry_count: int | None = 1
Integer value of retry count
- field sql_query: str | None = 'n/a'
sql query
- field status: str | None = None
status value
- field tables_used: List[str] | None = []
List of tables used
- field text_answer_llm: str | None = 'n/a'
LLM text answer
- field uuid: str | None = None
uuid of operation
- pydantic model V1Text2sqlFilters
Bases:
V1Filters
Show JSON schema
{ "title": "V1Text2sqlFilters", "type": "object", "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of created_by for this operation.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of uuids for this operation", "title": "Uuids" }, "name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of names for this operation.", "title": "Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses for this operation.", "title": "Status" } } }
- Config:
populate_by_name: bool = True
alias_generator: function = <function V1Text2sqlFilters.<lambda> at 0x7f98c4d7b1a0>
- Fields:
- field created_by: List[str] | None = None
List of created_by for this operation.
- field uuid: List[str] | None = None (alias 'uuids')
List of uuids for this operation
- pydantic model V1Text2sqlList
Bases:
RootModel
Show JSON schema
{ "title": "V1Text2sqlList", "type": "array", "$defs": { "V1BaseText2sql": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna io (link to qna_io table)", "title": "Qna Io Uuid" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "sql query", "title": "Sql Query" }, "generated_sql": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "generated sql", "title": "Generated Sql" }, "automated_query_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of automated query id", "title": "Automated Query Ids" }, "text_answer_llm": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "LLM text answer", "title": "Text Answer Llm" }, "tables_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of tables used", "title": "Tables Used" }, "columns_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of columns used", "title": "Columns Used" }, "retry_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "description": "Integer value of retry count", "title": "Retry Count" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "status value", "title": "Status" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "vianai", "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" } }, "title": "V1BaseText2sql", "type": "object" } }, "items": { "$ref": "#/$defs/V1BaseText2sql" } }
- field root: List[V1BaseText2sql] [Required]
- pydantic model V1Text2sqlPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1Text2sqlPage", "type": "object", "properties": { "items": { "default": [], "description": "Job Types returned by search in page.", "items": { "$ref": "#/$defs/V1Text2sqlResponse" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1Text2sqlResponse": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna io (link to qna_io table)", "title": "Qna Io Uuid" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "sql query", "title": "Sql Query" }, "generated_sql": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "generated sql", "title": "Generated Sql" }, "automated_query_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of automated query id", "title": "Automated Query Ids" }, "text_answer_llm": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "LLM text answer", "title": "Text Answer Llm" }, "tables_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of tables used", "title": "Tables Used" }, "columns_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of columns used", "title": "Columns Used" }, "retry_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "description": "Integer value of retry count", "title": "Retry Count" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "status value", "title": "Status" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the sql", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the sql", "title": "Modified By" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" } }, "title": "V1Text2sqlResponse", "type": "object" } } }
- field items: List[V1Text2sqlResponse] = []
Job Types returned by search in page.
- pydantic model V1Text2sqlResponse
Bases:
V1BaseText2sql
Show JSON schema
{ "title": "V1Text2sqlResponse", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna io (link to qna_io table)", "title": "Qna Io Uuid" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "sql query", "title": "Sql Query" }, "generated_sql": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "generated sql", "title": "Generated Sql" }, "automated_query_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of automated query id", "title": "Automated Query Ids" }, "text_answer_llm": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "LLM text answer", "title": "Text Answer Llm" }, "tables_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of tables used", "title": "Tables Used" }, "columns_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of columns used", "title": "Columns Used" }, "retry_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "description": "Integer value of retry count", "title": "Retry Count" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "status value", "title": "Status" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the sql", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the sql", "title": "Modified By" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" } } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field created_by: str | None = None
User that created the sql
- field created_ts: datetime | None = None
Unix time in milliseconds generated at creation time.
- field modified_by: str | None = None
User who modified the sql
- field modified_ts: datetime | None = None
Unix time in milliseconds generated at last modification time.
- field uuid: str | None = None
uuid
- pydantic model V1Text2sqlResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1Text2sqlResponseList", "type": "array", "$defs": { "V1Text2sqlResponse": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna io (link to qna_io table)", "title": "Qna Io Uuid" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "sql query", "title": "Sql Query" }, "generated_sql": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "generated sql", "title": "Generated Sql" }, "automated_query_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of automated query id", "title": "Automated Query Ids" }, "text_answer_llm": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "LLM text answer", "title": "Text Answer Llm" }, "tables_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of tables used", "title": "Tables Used" }, "columns_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of columns used", "title": "Columns Used" }, "retry_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "description": "Integer value of retry count", "title": "Retry Count" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "status value", "title": "Status" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that created the sql", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User who modified the sql", "title": "Modified By" }, "created_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at creation time.", "title": "Created Ts" } }, "title": "V1Text2sqlResponse", "type": "object" } }, "items": { "$ref": "#/$defs/V1Text2sqlResponse" } }
- field root: List[V1Text2sqlResponse] [Required]
- pydantic model V1Text2sqlSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1Text2sqlSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "anyOf": [ { "$ref": "#/$defs/V1Text2sqlFilters" }, { "type": "null" } ], "description": "Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved." } }, "$defs": { "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" }, "V1Text2sqlFilters": { "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of created_by for this operation.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of uuids for this operation", "title": "Uuids" }, "name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of names for this operation.", "title": "Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses for this operation.", "title": "Status" } }, "title": "V1Text2sqlFilters", "type": "object" } } }
- field filters: V1Text2sqlFilters | None = <class 'vianops_client.models.qnastore.qna_text2sql.V1Text2sqlFilters'>
Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved.
- pydantic model V1Text2sqlUpdates
Bases:
V1BaseText2sql
Show JSON schema
{ "title": "V1Text2sqlUpdates", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of operation", "title": "Uuid" }, "qna_io_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid of qna io (link to qna_io table)", "title": "Qna Io Uuid" }, "sql_query": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "sql query", "title": "Sql Query" }, "generated_sql": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "generated sql", "title": "Generated Sql" }, "automated_query_ids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of automated query id", "title": "Automated Query Ids" }, "text_answer_llm": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "n/a", "description": "LLM text answer", "title": "Text Answer Llm" }, "tables_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of tables used", "title": "Tables Used" }, "columns_used": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": [], "description": "List of columns used", "title": "Columns Used" }, "retry_count": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": 1, "description": "Integer value of retry count", "title": "Retry Count" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "status value", "title": "Status" }, "modified_ts": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds generated at last modification time.", "title": "Modified Ts" }, "created_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "vianai", "description": "User that created the qna io", "title": "Created By" }, "modified_by": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "User that modified the qna io", "title": "Modified By" }, "filters": { "anyOf": [ { "$ref": "#/$defs/V1Text2sqlFilters" }, { "type": "null" } ], "description": "Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved." } }, "$defs": { "V1Text2sqlFilters": { "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of created_by for this operation.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of uuids for this operation", "title": "Uuids" }, "name": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of names for this operation.", "title": "Name" }, "status": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of statuses for this operation.", "title": "Status" } }, "title": "V1Text2sqlFilters", "type": "object" } } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field filters: V1Text2sqlFilters | None = <class 'vianops_client.models.qnastore.qna_text2sql.V1Text2sqlFilters'>
Specifies different condition(s) for filtering the results. If not provided, all relevant results are retrieved.
vianops_client.models.qnastore.qna_thread module
- pydantic model V1BaseQNAThread
Bases:
BaseModel
Show JSON schema
{ "title": "V1BaseQNAThread", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "Thread", "description": "QNA Thread name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread description", "title": "Description" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name", "title": "Sources" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the parent QNA Conversation, qna_conversation:UUID", "title": "Qna Conversation Uuid" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_value, positive or negative", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_comment, user comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the QNA Thread", "title": "Status" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" } } }
- Fields:
- field description: str | None = None
QNA Thread description
- field feedback_comment: str | None = None
QNA Thread feedback_comment, user comment
- field feedback_value: bool | None = None
QNA Thread feedback_value, positive or negative
- field is_favorite: bool | None = None
flag to make favorite QNA Thread
- field is_pinned: bool | None = None
flag to pin QNA Thread
- field name: str | None = 'Thread'
QNA Thread name
- field qna_conversation_uuid: str | None = None
UUID of the parent QNA Conversation, qna_conversation:UUID
- field sources: List[str] | None = None
List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name
- field status: str | None = 'CREATED'
Status of the QNA Thread
- field uuid: str | None = None
uuid
- pydantic model V1QNAThreadFilters
Bases:
V1FiltersCommon
Show JSON schema
{ "title": "V1QNAThreadFilters", "type": "object", "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QNA Thread uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QNA Thread names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of sources for this operation.", "title": "Sources" }, "qna_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna_conversation_uuid for this operation.", "title": "Qna Conversation Uuids" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of feedback_value for this operation.", "title": "Feedback Value" }, "feedback_comments": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of feedback_comment for this operation.", "title": "Feedback Comments" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" } }, "example": { "names": [ "Example QNA Thread name" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] } }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
alias_generator: function = <function V1QNAThreadFilters.<lambda> at 0x7f98c4d7af20>
json_schema_extra: dict = {‘example’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example QNA Thread name’]}}
- Fields:
- field description: List[str] | None = None (alias 'descriptions')
List of descriptions for this operation.
- field feedback_comment: List[str] | None = None (alias 'feedback_comments')
List of feedback_comment for this operation.
- field feedback_value: bool | None = None
List of feedback_value for this operation.
- field is_favorite: bool | None = None
flag to make favorite QNA Thread
- field is_pinned: bool | None = None
flag to pin QNA Thread
- field name: List[str] | None = None (alias 'names')
List of QNA Thread names for this operation.
- field qna_conversation_uuid: List[str] | None = None (alias 'qna_conversation_uuids')
List of qna_conversation_uuid for this operation.
- field sources: List[str] | None = None
List of sources for this operation.
- field status: List[str] | None = None (alias 'statuses')
List of status for this operation.
- field uuid: List[str] | None = None (alias 'uuids')
List of QNA Thread uuids for this operation.
- pydantic model V1QNAThreadList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAThreadList", "type": "array", "$defs": { "V1BaseQNAThread": { "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "Thread", "description": "QNA Thread name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread description", "title": "Description" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name", "title": "Sources" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the parent QNA Conversation, qna_conversation:UUID", "title": "Qna Conversation Uuid" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_value, positive or negative", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_comment, user comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the QNA Thread", "title": "Status" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" } }, "title": "V1BaseQNAThread", "type": "object" } }, "items": { "$ref": "#/$defs/V1BaseQNAThread" } }
- field root: List[V1BaseQNAThread] [Required]
- pydantic model V1QNAThreadPage
Bases:
V1PageModel
Show JSON schema
{ "title": "V1QNAThreadPage", "type": "object", "properties": { "items": { "default": [], "description": "Job Types returned by search in page.", "items": { "$ref": "#/$defs/V1QNAThreadResponse" }, "title": "Items", "type": "array" }, "current_page": { "default": 0, "description": "Current page of items.", "title": "Current Page", "type": "integer" }, "page_size": { "default": 0, "description": "Number of items on a page.", "title": "Page Size", "type": "integer" }, "previous_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the previous page.", "title": "Previous Page" }, "next_page": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of the next page.", "title": "Next Page" }, "has_previous": { "default": false, "description": "Whether or not there is a previous page.", "title": "Has Previous", "type": "boolean" }, "previous_items": { "default": 0, "title": "Previous Items", "type": "integer" }, "has_next": { "default": false, "description": "Whether or not there is a next page.", "title": "Has Next", "type": "boolean" }, "total": { "default": 0, "description": "Total number of items returned by search over all pages.", "title": "Total", "type": "integer" }, "pages": { "default": 0, "description": "Total number of pages returned by search.", "title": "Pages", "type": "integer" } }, "$defs": { "V1QNAThreadResponse": { "properties": { "uuid": { "description": "uuid", "title": "Uuid", "type": "string" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "Thread", "description": "QNA Thread name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread description", "title": "Description" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name", "title": "Sources" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the parent QNA Conversation, qna_conversation:UUID", "title": "Qna Conversation Uuid" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_value, positive or negative", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_comment, user comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the QNA Thread", "title": "Status" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Thread", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Thread", "title": "Modified By", "type": "string" } }, "required": [ "uuid", "created_ts", "modified_ts", "created_by", "modified_by" ], "title": "V1QNAThreadResponse", "type": "object" } } }
- field items: List[V1QNAThreadResponse] = []
Job Types returned by search in page.
- pydantic model V1QNAThreadResponse
Bases:
V1BaseQNAThread
Show JSON schema
{ "title": "V1QNAThreadResponse", "type": "object", "properties": { "uuid": { "description": "uuid", "title": "Uuid", "type": "string" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "Thread", "description": "QNA Thread name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread description", "title": "Description" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name", "title": "Sources" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the parent QNA Conversation, qna_conversation:UUID", "title": "Qna Conversation Uuid" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_value, positive or negative", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_comment, user comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the QNA Thread", "title": "Status" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Thread", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Thread", "title": "Modified By", "type": "string" } }, "required": [ "uuid", "created_ts", "modified_ts", "created_by", "modified_by" ] }
- Config:
from_attributes: bool = True
populate_by_name: bool = True
- Fields:
- field created_by: str [Required]
User that created the QNA Thread
- field created_ts: datetime [Required]
Unix time in milliseconds generated at creation time.
- field modified_by: str [Required]
User who modified the QNA Thread
- field modified_ts: datetime [Required]
Unix time in milliseconds generated at last modification time.
- field uuid: str [Required]
uuid
- pydantic model V1QNAThreadResponseList
Bases:
RootModel
Show JSON schema
{ "title": "V1QNAThreadResponseList", "type": "array", "$defs": { "V1QNAThreadResponse": { "properties": { "uuid": { "description": "uuid", "title": "Uuid", "type": "string" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "Thread", "description": "QNA Thread name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread description", "title": "Description" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name", "title": "Sources" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the parent QNA Conversation, qna_conversation:UUID", "title": "Qna Conversation Uuid" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_value, positive or negative", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_comment, user comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the QNA Thread", "title": "Status" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" }, "created_ts": { "description": "Unix time in milliseconds generated at creation time.", "format": "date-time", "title": "Created Ts", "type": "string" }, "modified_ts": { "description": "Unix time in milliseconds generated at last modification time.", "format": "date-time", "title": "Modified Ts", "type": "string" }, "created_by": { "description": "User that created the QNA Thread", "title": "Created By", "type": "string" }, "modified_by": { "description": "User who modified the QNA Thread", "title": "Modified By", "type": "string" } }, "required": [ "uuid", "created_ts", "modified_ts", "created_by", "modified_by" ], "title": "V1QNAThreadResponse", "type": "object" } }, "items": { "$ref": "#/$defs/V1QNAThreadResponse" } }
- field root: List[V1QNAThreadResponse] [Required]
- pydantic model V1QNAThreadSearch
Bases:
V1PageSearch
Show JSON schema
{ "title": "V1QNAThreadSearch", "type": "object", "properties": { "page": { "default": 1, "description": "Page number to return. Zero-index based. Cannot be less than zero or greater than number of pages. To make sure you don't exceed the number of pages, set `page` to 1 and run this search operation to return the total number items (`total`). Then run it again to return the exact page (`page`) for the specified number of items per page (`page-size`).", "title": "Page", "type": "integer" }, "page_size": { "default": 25, "description": "Number of items to return on a page. Default is 25 items per page.", "title": "Page Size", "type": "integer" }, "order": { "anyOf": [ { "items": { "$ref": "#/$defs/V1OrderBy" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "Fields to use for ordering returned pages and the sort direction.", "title": "Order" }, "search": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "String to search for (case-insensitive) across all fields in previously created items.", "title": "Search" }, "filters": { "$ref": "#/$defs/V1QNAThreadFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1OrderBy": { "properties": { "field": { "description": "Field to order by.", "title": "Field", "type": "string" }, "direction": { "default": "ASC", "description": "Direction to order the field by. Supported values: `ASC` (ascending) and `DESC` (descending) (case-insensitive).", "enum": [ "ASC", "DESC" ], "title": "Direction", "type": "string" } }, "required": [ "field" ], "title": "V1OrderBy", "type": "object" }, "V1QNAThreadFilters": { "example": { "names": [ "Example QNA Thread name" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QNA Thread uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QNA Thread names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of sources for this operation.", "title": "Sources" }, "qna_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna_conversation_uuid for this operation.", "title": "Qna Conversation Uuids" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of feedback_value for this operation.", "title": "Feedback Value" }, "feedback_comments": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of feedback_comment for this operation.", "title": "Feedback Comments" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" } }, "title": "V1QNAThreadFilters", "type": "object" } }, "example": { "filters": { "names": [ "Example QNA Thread metrics" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "order": [ { "direction": "DESC", "field": "name" } ], "page": 1, "page_size": 100, "search": "vianai" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘page’: 1, ‘page_size’: 100, ‘order’: [{‘field’: ‘name’, ‘direction’: ‘DESC’}], ‘search’: ‘vianai’, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example QNA Thread metrics’]}}}
- Fields:
- field filters: V1QNAThreadFilters [Required]
Specifies different condition(s) for filtering the results.
- pydantic model V1QNAThreadUpdates
Bases:
V1BaseQNAThread
Show JSON schema
{ "title": "V1QNAThreadUpdates", "type": "object", "properties": { "uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "uuid", "title": "Uuid" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread name", "title": "Name" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread description", "title": "Description" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of data sources. e.g. qna_metadata:UUID, model:UUID, RAG:name", "title": "Sources" }, "qna_conversation_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UUID of the parent QNA Conversation, qna_conversation:UUID", "title": "Qna Conversation Uuid" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_value, positive or negative", "title": "Feedback Value" }, "feedback_comment": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "QNA Thread feedback_comment, user comment", "title": "Feedback Comment" }, "status": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": "CREATED", "description": "Status of the QNA Thread", "title": "Status" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" }, "filters": { "$ref": "#/$defs/V1QNAThreadFilters", "description": "Specifies different condition(s) for filtering the results." } }, "$defs": { "V1QNAThreadFilters": { "example": { "names": [ "Example QNA Thread name" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "properties": { "created_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'created by' users to search for.", "title": "Created By" }, "modified_by": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of 'modified by' users to search for.", "title": "Modified By" }, "created_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts Start" }, "created_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects created during a specified time period.", "title": "Created Ts End" }, "modified_ts_start": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts Start" }, "modified_ts_end": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "default": null, "description": "Unix time in milliseconds for searching for all objects modified during a specified time period.", "title": "Modified Ts End" }, "uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QNA Thread uuids for this operation.", "title": "Uuids" }, "names": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of QNA Thread names for this operation.", "title": "Names" }, "descriptions": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of descriptions for this operation.", "title": "Descriptions" }, "sources": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of sources for this operation.", "title": "Sources" }, "qna_conversation_uuids": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of qna_conversation_uuid for this operation.", "title": "Qna Conversation Uuids" }, "feedback_value": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "List of feedback_value for this operation.", "title": "Feedback Value" }, "feedback_comments": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of feedback_comment for this operation.", "title": "Feedback Comments" }, "statuses": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "description": "List of status for this operation.", "title": "Statuses" }, "is_pinned": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to pin QNA Thread", "title": "Is Pinned" }, "is_favorite": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "flag to make favorite QNA Thread", "title": "Is Favorite" } }, "title": "V1QNAThreadFilters", "type": "object" } }, "example": { "description": "Updated QNA Thread description", "filters": { "names": [ "Example QNA Thread name" ], "uuids": [ "5efc9544-e84a-4a94-9e6d-5774e1c609ab", "9140dd05-3f7a-49a4-b625-379880bd9606" ] }, "name": "Updated QNA Thread name" }, "required": [ "filters" ] }
- Config:
json_schema_extra: dict = {‘example’: {‘name’: ‘Updated QNA Thread name’, ‘description’: ‘Updated QNA Thread description’, ‘filters’: {‘uuids’: [‘5efc9544-e84a-4a94-9e6d-5774e1c609ab’, ‘9140dd05-3f7a-49a4-b625-379880bd9606’], ‘names’: [‘Example QNA Thread name’]}}}
- Fields:
- field description: str | None = None
QNA Thread description
- field filters: V1QNAThreadFilters [Required]
Specifies different condition(s) for filtering the results.
- field name: str | None = None
QNA Thread name