Document¶
- pydantic model schemas.document.DocumentBase¶
Base class for Document
Show JSON schema
{ "title": "DocumentBase", "description": "Base class for Document", "type": "object", "properties": { "text": { "title": "Text", "type": "string" }, "url": { "title": "Url", "type": "string" }, "language": { "default": null, "title": "Language", "type": "string" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags" }, "subtopics": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Summary" }, "hyq": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq" }, "hyq_declarative": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative" }, "doctype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Doctype" }, "organizations": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Organizations" }, "user_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "User Uuid" } }, "required": [ "text", "url" ] }
- Config:
arbitrary_types_allowed: bool = True
- Fields:
- field doctype: str | None = None¶
Type of the document
- field hyq: List[str] | None = None¶
Hypothetical queries associated to the document text
- field hyq_declarative: List[str] | None = None¶
Declarative hypothetical queries associated to the document text
- field language: str = None¶
Language of the document text
- field organizations: List[str] | None = None¶
Organizations to which the document belongs
- field subtopics: List[str] | None = None¶
Subtopics of the document text
- field summary: str | None = None¶
Summary of the document text
- field tags: List[str] | None = None¶
Tags of the document text
- field text: str [Required]¶
Content of the document
- field url: str [Required]¶
URL where the document was found
- field user_uuid: str | None = None¶
UUID of the user who added the document
- pydantic model schemas.document.DocumentCreate¶
Create class for Document
Show JSON schema
{ "title": "DocumentCreate", "description": "Create class for Document", "type": "object", "properties": { "text": { "title": "Text", "type": "string" }, "url": { "title": "Url", "type": "string" }, "language": { "default": null, "title": "Language", "type": "string" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags" }, "subtopics": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Summary" }, "hyq": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq" }, "hyq_declarative": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative" }, "doctype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Doctype" }, "organizations": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Organizations" }, "user_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "User Uuid" }, "text_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Text Embedding" }, "tags_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags Embedding" }, "subtopics_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics Embedding" }, "summary_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Summary Embedding" }, "hyq_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Embedding" }, "hyq_declarative_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative Embedding" }, "source": { "title": "Source", "type": "string" } }, "required": [ "text", "url", "source" ] }
- Config:
arbitrary_types_allowed: bool = True
- Fields:
- field doctype: str | None = None¶
Type of the document
- field hyq: List[str] | None = None¶
Hypothetical queries associated to the document text
- field hyq_declarative: List[str] | None = None¶
Declarative hypothetical queries associated to the document text
- field hyq_declarative_embedding: list[float] | None = None¶
- field hyq_embedding: list[float] | None = None¶
- field language: str = None¶
Language of the document text
- field organizations: List[str] | None = None¶
Organizations to which the document belongs
- field source: str [Required]¶
How the document was found, can be a URL or a file path for example
- field subtopics: List[str] | None = None¶
Subtopics of the document text
- field subtopics_embedding: list[float] | None = None¶
- field summary: str | None = None¶
Summary of the document text
- field summary_embedding: list[float] | None = None¶
- field tags: List[str] | None = None¶
Tags of the document text
- field tags_embedding: list[float] | None = None¶
- field text: str [Required]¶
Content of the document
- field text_embedding: list[float] | None = None¶
- field url: str [Required]¶
URL where the document was found
- field user_uuid: str | None = None¶
UUID of the user who added the document
- pydantic model schemas.document.DocumentsCreate¶
Create class for Documents
Show JSON schema
{ "title": "DocumentsCreate", "description": "Create class for Documents", "type": "object", "properties": { "objects": { "items": { "$ref": "#/$defs/DocumentCreate" }, "title": "Objects", "type": "array" } }, "$defs": { "DocumentCreate": { "description": "Create class for Document", "properties": { "text": { "title": "Text", "type": "string" }, "url": { "title": "Url", "type": "string" }, "language": { "default": null, "title": "Language", "type": "string" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags" }, "subtopics": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Summary" }, "hyq": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq" }, "hyq_declarative": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative" }, "doctype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Doctype" }, "organizations": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Organizations" }, "user_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "User Uuid" }, "text_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Text Embedding" }, "tags_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags Embedding" }, "subtopics_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics Embedding" }, "summary_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Summary Embedding" }, "hyq_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Embedding" }, "hyq_declarative_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative Embedding" }, "source": { "title": "Source", "type": "string" } }, "required": [ "text", "url", "source" ], "title": "DocumentCreate", "type": "object" } }, "required": [ "objects" ] }
- field objects: list[DocumentCreate] [Required]¶
A list of documents to add to the database
- pydantic model schemas.document.DocumentUpdate¶
Update class for Document
Show JSON schema
{ "title": "DocumentUpdate", "description": "Update class for Document", "type": "object", "properties": { "text": { "title": "Text", "type": "string" }, "url": { "title": "Url", "type": "string" }, "language": { "default": null, "title": "Language", "type": "string" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags" }, "subtopics": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Summary" }, "hyq": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq" }, "hyq_declarative": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative" }, "doctype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Doctype" }, "organizations": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Organizations" }, "user_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "User Uuid" }, "source_id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Source Id" }, "text_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Text Embedding" }, "subtopics_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics Embedding" }, "tags_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags Embedding" }, "summary_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Summary Embedding" }, "hyq_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Embedding" }, "hyq_declarative_embedding": { "anyOf": [ { "items": { "type": "number" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative Embedding" } }, "required": [ "text", "url" ] }
- Config:
arbitrary_types_allowed: bool = True
- Fields:
- field doctype: str | None = None¶
Type of the document
- field hyq: List[str] | None = None¶
Hypothetical queries associated to the document text
- field hyq_declarative: List[str] | None = None¶
Declarative hypothetical queries associated to the document text
- field hyq_declarative_embedding: list[float] | None = None¶
- field hyq_embedding: list[float] | None = None¶
- field language: str = None¶
Language of the document text
- field organizations: List[str] | None = None¶
Organizations to which the document belongs
- field source_id: int | None = None¶
- field subtopics: List[str] | None = None¶
Subtopics of the document text
- field subtopics_embedding: list[float] | None = None¶
- field summary: str | None = None¶
Summary of the document text
- field summary_embedding: list[float] | None = None¶
- field tags: List[str] | None = None¶
Tags of the document text
- field tags_embedding: list[float] | None = None¶
- field text: str [Required]¶
Content of the document
- field text_embedding: list[float] | None = None¶
- field url: str [Required]¶
URL where the document was found
- field user_uuid: str | None = None¶
UUID of the user who added the document
- pydantic model schemas.document.Document¶
Show JSON schema
{ "title": "Document", "type": "object", "properties": { "text": { "default": "", "title": "Text", "type": "string" }, "url": { "default": "", "title": "Url", "type": "string" }, "language": { "default": null, "title": "Language", "type": "string" }, "tags": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Tags" }, "subtopics": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Subtopics" }, "summary": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Summary" }, "hyq": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq" }, "hyq_declarative": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Hyq Declarative" }, "doctype": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "Doctype" }, "organizations": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "default": null, "title": "Organizations" }, "user_uuid": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "title": "User Uuid" }, "id": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "default": null, "title": "Id" } } }
- Config:
arbitrary_types_allowed: bool = True
from_attributes: bool = True
- Fields:
- field doctype: str | None = None¶
Type of the document
- field hyq: List[str] | None = None¶
Hypothetical queries associated to the document text
- field hyq_declarative: List[str] | None = None¶
Declarative hypothetical queries associated to the document text
- field id: int | None = None¶
- field language: str = None¶
Language of the document text
- field organizations: List[str] | None = None¶
Organizations to which the document belongs
- field subtopics: List[str] | None = None¶
Subtopics of the document text
- field summary: str | None = None¶
Summary of the document text
- field tags: List[str] | None = None¶
Tags of the document text
- field text: str = ''¶
Content of the document
- field url: str = ''¶
URL where the document was found
- field user_uuid: str | None = None¶
UUID of the user who added the document