> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.emtelligent.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.emtelligent.com/_mcp/server.

# db.schemas.legacy.models

This module contains all the ORM models, implemented using SQLAlchemy.

The attributes of each object are documented as being either 'column' or
'dynamic'; 'column' means they're actual columns in the database table, and
'dynamic' means they're only convenience attributes created by the ORM to
handle relationships.

Note that the actual data types used when creating tables depends on the SQL
dialect used (i.e. which database it's connected to). To check the exact data
types, one can refer to SQLAlchemy's documentation, or inspect the schema of
the tables that were created using this tool.

NOTE: back-references may not always be documented.

## Module Contents

### Classes

| Name                                                                                                         | Description                                                                                                                                                                                                                               |
| ------------------------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`Base`](#emtelliprodbschemaslegacymodelsbase)                                                               | The base of all tables.                                                                                                                                                                                                                   |
| [`AlembicVersion`](#emtelliprodbschemaslegacymodelsalembicversion)                                           | Table containg the alembic version. It's defined here so that we can easily create and drop it along with all the other tables.                                                                                                           |
| [`ProcessingDetails`](#emtelliprodbschemaslegacymodelsprocessingdetails)                                     | Table containing details about the job submitted for processing.                                                                                                                                                                          |
| [`DocumentMetadata`](#emtelliprodbschemaslegacymodelsdocumentmetadata)                                       | Table containing arbitrary metadata for each document.                                                                                                                                                                                    |
| [`DocumentStructuredMetadata`](#emtelliprodbschemaslegacymodelsdocumentstructuredmetadata)                   | Table containing arbitrary metadata for each document.                                                                                                                                                                                    |
| [`Document`](#emtelliprodbschemaslegacymodelsdocument)                                                       | Table containing details specific the the overall document that was processed.                                                                                                                                                            |
| [`DocumentSourceChunk`](#emtelliprodbschemaslegacymodelsdocumentsourcechunk)                                 | Table containing chunks of source data.                                                                                                                                                                                                   |
| [`OntologyVersion`](#emtelliprodbschemaslegacymodelsontologyversion)                                         | Table of ontology versions for each document.                                                                                                                                                                                             |
| [`Entity`](#emtelliprodbschemaslegacymodelsentity)                                                           | Table of entities stored in a specific document. The entity information is stored in different tables depending on entity type. The `type_` column can be used along with the `entity_id` to determine which exact entity is referred to. |
| [`AssumedEntity`](#emtelliprodbschemaslegacymodelsassumedentity)                                             | Table containing assumed entities.                                                                                                                                                                                                        |
| [`FoundEntity`](#emtelliprodbschemaslegacymodelsfoundentity)                                                 | Table containing found entities.                                                                                                                                                                                                          |
| [`FoundEntityMeasurementUnit`](#emtelliprodbschemaslegacymodelsfoundentitymeasurementunit)                   | Table containing the measurement units for a found entity                                                                                                                                                                                 |
| [`FoundEntityType`](#emtelliprodbschemaslegacymodelsfoundentitytype)                                         | Table containing the type_name information from found entities.                                                                                                                                                                           |
| [`Concept`](#emtelliprodbschemaslegacymodelsconcept)                                                         | Table containing information about a specific column, with the primary keys being the `concept_id` and `ontology`.                                                                                                                        |
| [`FoundEntitySpan`](#emtelliprodbschemaslegacymodelsfoundentityspan)                                         | Table containging spans contained in found entities.                                                                                                                                                                                      |
| [`SentenceLocation`](#emtelliprodbschemaslegacymodelssentencelocation)                                       | Table containing sentence locations. It exists mainly as a link between the locations table and the spans.                                                                                                                                |
| [`SentenceLocationSpan`](#emtelliprodbschemaslegacymodelssentencelocationspan)                               | Table containing sentence location spans                                                                                                                                                                                                  |
| [`HeadingLocation`](#emtelliprodbschemaslegacymodelsheadinglocation)                                         | Table containing heading locations. It exists mainly as a link between the locations table and the spans.                                                                                                                                 |
| [`HeadingLocationSpan`](#emtelliprodbschemaslegacymodelsheadinglocationspan)                                 | Table containing heading location spans                                                                                                                                                                                                   |
| [`PageLocation`](#emtelliprodbschemaslegacymodelspagelocation)                                               | Table containing page locations. It exists mainly as a link between the locations table and the spans.                                                                                                                                    |
| [`PageLocationSpan`](#emtelliprodbschemaslegacymodelspagelocationspan)                                       | Table containing page location spans                                                                                                                                                                                                      |
| [`PageSection`](#emtelliprodbschemaslegacymodelspagesection)                                                 | Table containing links between pages and section, with a composite primary key of `page_id` and `section_id`.                                                                                                                             |
| [`Relation`](#emtelliprodbschemaslegacymodelsrelation)                                                       | Table containing links to all the different kinds of relations. Use the `type_` and `relation_id` fields to find the actual relation in one of the other `*Relation` tables.                                                              |
| [`Location`](#emtelliprodbschemaslegacymodelslocation)                                                       | Table containing links to all the different kinds of locations. Use the `type_` and `location_id` fields to find the actual location in one of the other `*Location` tables.                                                              |
| [`SectionLocationSpan`](#emtelliprodbschemaslegacymodelssectionlocationspan)                                 | Table containing sentence location span information.                                                                                                                                                                                      |
| [`ImageLinkRelation`](#emtelliprodbschemaslegacymodelsimagelinkrelation)                                     | Table containing image link relation information.                                                                                                                                                                                         |
| [`FollowupRelation`](#emtelliprodbschemaslegacymodelsfollowuprelation)                                       | Table containign follow-up relation information.                                                                                                                                                                                          |
| [`ExperiencerRelation`](#emtelliprodbschemaslegacymodelsexperiencerrelation)                                 | Table containing experience relation information.                                                                                                                                                                                         |
| [`MeasurementRelation`](#emtelliprodbschemaslegacymodelsmeasurementrelation)                                 | Table containing measurement relations.                                                                                                                                                                                                   |
| [`QualifierRelation`](#emtelliprodbschemaslegacymodelsqualifierrelation)                                     | Table containing qualifier relations.                                                                                                                                                                                                     |
| [`MedicationRelation`](#emtelliprodbschemaslegacymodelsmedicationrelation)                                   | Table containing medication relations.                                                                                                                                                                                                    |
| [`TemporalityRelation`](#emtelliprodbschemaslegacymodelstemporalityrelation)                                 | Table containing temporality relations.                                                                                                                                                                                                   |
| [`ReportedEventRelation`](#emtelliprodbschemaslegacymodelsreportedeventrelation)                             | Table containing reported event relations.                                                                                                                                                                                                |
| [`AnatomicSiteRelation`](#emtelliprodbschemaslegacymodelsanatomicsiterelation)                               | Table containing anatomic site relations.                                                                                                                                                                                                 |
| [`SectionLocation`](#emtelliprodbschemaslegacymodelssectionlocation)                                         | Table containg section locations.                                                                                                                                                                                                         |
| [`SentenceSection`](#emtelliprodbschemaslegacymodelssentencesection)                                         | Table containing links between sentences and section, with a composite primary key of `sentence_id` and `section_id`.                                                                                                                     |
| [`DocumentConcept`](#emtelliprodbschemaslegacymodelsdocumentconcept)                                         | Association table linking documents to concepts.                                                                                                                                                                                          |
| [`FoundEntityConcept`](#emtelliprodbschemaslegacymodelsfoundentityconcept)                                   | Association table linking found entities to concepts.                                                                                                                                                                                     |
| [`FoundEntityLocation`](#emtelliprodbschemaslegacymodelsfoundentitylocation)                                 | Association table linking found entities to locations.                                                                                                                                                                                    |
| [`ImageLinkRelationImageFinding`](#emtelliprodbschemaslegacymodelsimagelinkrelationimagefinding)             | Association table linking image link relations to entities specified as image findings.                                                                                                                                                   |
| [`ImageLinkRelationReference`](#emtelliprodbschemaslegacymodelsimagelinkrelationreference)                   | Association table linking image link relations to entities specified as references.                                                                                                                                                       |
| [`FollowupRelationProcedure`](#emtelliprodbschemaslegacymodelsfollowuprelationprocedure)                     | Association table linking followup relations to entities specified as procedures.                                                                                                                                                         |
| [`FollowupRelationReason`](#emtelliprodbschemaslegacymodelsfollowuprelationreason)                           | Association table linking followup relations to entities specified as reasons.                                                                                                                                                            |
| [`MedicationRelationDosage`](#emtelliprodbschemaslegacymodelsmedicationrelationdosage)                       | Association table linking medication relations to entities specified as dosage                                                                                                                                                            |
| [`MedicationRelationFrequency`](#emtelliprodbschemaslegacymodelsmedicationrelationfrequency)                 | Association table linking medication relations to entities specified as frequency                                                                                                                                                         |
| [`MedicationRelationMode`](#emtelliprodbschemaslegacymodelsmedicationrelationmode)                           | Association table linking medication relations to entities specified as mode                                                                                                                                                              |
| [`MedicationRelationQuantity`](#emtelliprodbschemaslegacymodelsmedicationrelationquantity)                   | Association table linking medication relations to entities specified as quantity                                                                                                                                                          |
| [`MedicationRelationRoute`](#emtelliprodbschemaslegacymodelsmedicationrelationroute)                         | Association table linking medication relations to entities specified as route                                                                                                                                                             |
| [`MedicationRelationNecessity`](#emtelliprodbschemaslegacymodelsmedicationrelationnecessity)                 | Association table linking medication relations to entities specified as route                                                                                                                                                             |
| [`MedicationRelationModifier`](#emtelliprodbschemaslegacymodelsmedicationrelationmodifier)                   | Association table linking medication relations to entities specified as route                                                                                                                                                             |
| [`MedicationRelationDuration`](#emtelliprodbschemaslegacymodelsmedicationrelationduration)                   | Association table linking medication relations to entities specified as duration                                                                                                                                                          |
| [`MedicationRelationIndication`](#emtelliprodbschemaslegacymodelsmedicationrelationindication)               | Association table linking medication relations to entities specified as indication                                                                                                                                                        |
| [`MedicationRelationDatetime`](#emtelliprodbschemaslegacymodelsmedicationrelationdatetime)                   | Association table linking medication relations to entities specified as datetimes.                                                                                                                                                        |
| [`TemporalityRelationModifier`](#emtelliprodbschemaslegacymodelstemporalityrelationmodifier)                 | Association table linking temporality relations to entities specified as modifiers                                                                                                                                                        |
| [`ReportedEventRelationToEntity`](#emtelliprodbschemaslegacymodelsreportedeventrelationtoentity)             | Association table linking reported-event relations to entities which were recipients of the communication.                                                                                                                                |
| [`ReportedEventRelationFromEntity`](#emtelliprodbschemaslegacymodelsreportedeventrelationfromentity)         | Association table linking reported-event relations to entities which were sources of the communication.                                                                                                                                   |
| [`ReportedEventRelationMethod`](#emtelliprodbschemaslegacymodelsreportedeventrelationmethod)                 | Association table linking reported-event relations to entities which were the methods of communication                                                                                                                                    |
| [`ReportedEventRelationTimeExpression`](#emtelliprodbschemaslegacymodelsreportedeventrelationtimeexpression) | Association table linking reported-event relations to entities which were the time expressions that indicate when the communication took place                                                                                            |

### Functions

| Name                                                                   | Description                                 |
| ---------------------------------------------------------------------- | ------------------------------------------- |
| [`recreate_indexes`](#emtelliprodbschemaslegacymodelsrecreate_indexes) | Re-create all the full text search indexes. |

### Data

`_supported_indexes_for`
`_model_type_registry`

### API

#### `emtellipro.db.schemas.legacy.models.Base`

```python
class emtellipro.db.schemas.legacy.models.Base
```

**Bases:** `DeclarativeBase`

**Bases**: `sqlalchemy.orm.DeclarativeBase`

The base of all tables.

##### `Base.metadata`

```python
metadata
```

The MetaData instance specific to this base class.

**Value**: `create_metadata(...)`

##### `Base.__tablename__`

```python
__tablename__()
```

#### `emtellipro.db.schemas.legacy.models.AlembicVersion`

```python
class emtellipro.db.schemas.legacy.models.AlembicVersion
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containg the alembic version. It's defined here so that we can easily
create and drop it along with all the other tables.

##### `AlembicVersion.__tablename__`

```python
__tablename__
```

**Value**: `alembic_version`

##### `AlembicVersion.version_num`

```python
version_num
```

**Value**: `Column(...)`

##### `AlembicVersion.__table_args__`

```python
__table_args__
```

**Value**: `()`

#### `emtellipro.db.schemas.legacy.models.ProcessingDetails`

```python
class emtellipro.db.schemas.legacy.models.ProcessingDetails
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing details about the job submitted for processing.

##### `ProcessingDetails.id`

```python
id
```

**Value**: `Column(...)`

##### `ProcessingDetails.job_id`

```python
job_id
```

**Value**: `Column(...)`

##### `ProcessingDetails.submit_timestamp`

```python
submit_timestamp
```

**Value**: `Column(...)`

##### `ProcessingDetails.task_id`

```python
task_id
```

**Value**: `Column(...)`

##### `ProcessingDetails.engine_version`

```python
engine_version
```

**Value**: `Column(...)`

##### `ProcessingDetails.sdk_version`

```python
sdk_version
```

**Value**: `Column(...)`

##### `ProcessingDetails.sql_query`

```python
sql_query
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.DocumentMetadata`

```python
class emtellipro.db.schemas.legacy.models.DocumentMetadata
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing arbitrary metadata for each document.

##### `DocumentMetadata.id`

```python
id
```

**Value**: `Column(...)`

##### `DocumentMetadata.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `DocumentMetadata.document`

```python
document
```

**Value**: `relationship(...)`

##### `DocumentMetadata.source_document_id`

```python
source_document_id
```

**Value**: `Column(...)`

##### `DocumentMetadata.source_document_id_2`

```python
source_document_id_2
```

**Value**: `Column(...)`

##### `DocumentMetadata.source_document_id_3`

```python
source_document_id_3
```

**Value**: `Column(...)`

##### `DocumentMetadata.original_category`

```python
original_category
```

**Value**: `Column(...)`

##### `DocumentMetadata.original_subcategory`

```python
original_subcategory
```

**Value**: `Column(...)`

##### `DocumentMetadata.clinical_domain`

```python
clinical_domain
```

**Value**: `Column(...)`

##### `DocumentMetadata.institution`

```python
institution
```

**Value**: `Column(...)`

##### `DocumentMetadata.subject_id`

```python
subject_id
```

**Value**: `Column(...)`

##### `DocumentMetadata.subject_id_2`

```python
subject_id_2
```

**Value**: `Column(...)`

##### `DocumentMetadata.description`

```python
description
```

**Value**: `Column(...)`

##### `DocumentMetadata.hadm_id`

```python
hadm_id
```

**Value**: `Column(...)`

##### `DocumentMetadata.chartdate`

```python
chartdate
```

**Value**: `Column(...)`

##### `DocumentMetadata.encounterdate`

```python
encounterdate
```

**Value**: `Column(...)`

##### `DocumentMetadata.author_name`

```python
author_name
```

**Value**: `Column(...)`

##### `DocumentMetadata.subject_name`

```python
subject_name
```

**Value**: `Column(...)`

##### `DocumentMetadata.subject_dob`

```python
subject_dob
```

**Value**: `Column(...)`

##### `DocumentMetadata.subject_gender`

```python
subject_gender
```

**Value**: `Column(...)`

##### `DocumentMetadata.subject_address`

```python
subject_address
```

**Value**: `Column(...)`

##### `DocumentMetadata.requestor`

```python
requestor
```

**Value**: `Column(...)`

##### `DocumentMetadata.document_summary`

```python
document_summary
```

**Value**: `Column(...)`

##### `DocumentMetadata.predefined_names`

```python
predefined_names
```

The list of valid metadata columns in this table. This can be used to
parse metadata out of other objects to determine what should go in this
table vs. the `DocumentStructuredMetadata` table.

**Value**: `['author_name', 'chartdate', 'encounterdate', 'clinical_domain', 'description', 'document_summary', 'hadm_id', 'institution', 'original_category', 'original_subcategory', 'requestor', 'source_document_id', 'source_document_id_2', 'source_document_id_3', 'subject_address', 'subject_dob', 'subject_gender', 'subject_id', 'subject_id_2', 'subject_name']`

##### `DocumentMetadata.__table_args__`

```python
__table_args__
```

**Value**: `()`

##### `DocumentMetadata.parse_dates`

```python
parse_dates(
    metadata, parse_dates = False
)
```

Optionally parse dates in the metadata. This also converts empty
strings to None.

**Parameters:**

**`metadata`**

a metadata dictionary

---

**`parse_dates`**

whether to actually parse the dates in the
metadata dict. Parsing dates is only relevant for certain
database types.

---

#### `emtellipro.db.schemas.legacy.models.DocumentStructuredMetadata`

```python
class emtellipro.db.schemas.legacy.models.DocumentStructuredMetadata
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing arbitrary metadata for each document.

##### `DocumentStructuredMetadata.id`

```python
id
```

**Value**: `Column(...)`

##### `DocumentStructuredMetadata.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `DocumentStructuredMetadata.document`

```python
document
```

**Value**: `relationship(...)`

##### `DocumentStructuredMetadata.key`

```python
key
```

**Value**: `Column(...)`

##### `DocumentStructuredMetadata.value`

```python
value
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.Document`

```python
class emtellipro.db.schemas.legacy.models.Document
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing details specific the the overall document that was
processed.

##### `Document.id`

```python
id
```

**Value**: `Column(...)`

##### `Document.category`

```python
category
```

**Value**: `Column(...)`

##### `Document.subcategory`

```python
subcategory
```

**Value**: `Column(...)`

##### `Document.filename`

```python
filename
```

**Value**: `Column(...)`

##### `Document.section_label`

```python
section_label
```

**Value**: `Column(...)`

##### `Document.text`

```python
text
```

**Value**: `Column(...)`

##### `Document.json_representation`

```python
json_representation
```

**Value**: `Column(...)`

##### `Document.processing_status`

```python
processing_status
```

**Value**: `Column(...)`

##### `Document.processing_details_id`

```python
processing_details_id
```

**Value**: `Column(...)`

##### `Document.source_type`

```python
source_type
```

**Value**: `Column(...)`

##### `Document.source_path`

```python
source_path
```

**Value**: `Column(...)`

##### `Document.source_size`

```python
source_size
```

**Value**: `Column(...)`

##### `Document.processing_details`

```python
processing_details
```

**Value**: `relationship(...)`

##### `Document.concepts`

```python
concepts
```

**Value**: `relationship(...)`

##### `Document.entities`

```python
entities
```

**Value**: `relationship(...)`

##### `Document.relations`

```python
relations
```

**Value**: `relationship(...)`

##### `Document.locations`

```python
locations
```

**Value**: `relationship(...)`

##### `Document.ontology_versions`

```python
ontology_versions
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.DocumentSourceChunk`

```python
class emtellipro.db.schemas.legacy.models.DocumentSourceChunk
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing chunks of source data.

This is useful for storing the original PDF data if you've extracted the
text from it and have used the plaintext for processing.

##### `DocumentSourceChunk.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `DocumentSourceChunk.offset`

```python
offset
```

**Value**: `Column(...)`

##### `DocumentSourceChunk.data`

```python
data
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.OntologyVersion`

```python
class emtellipro.db.schemas.legacy.models.OntologyVersion
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table of ontology versions for each document.

##### `OntologyVersion.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `OntologyVersion.ontology`

```python
ontology
```

**Value**: `Column(...)`

##### `OntologyVersion.release_version`

```python
release_version
```

**Value**: `Column(...)`

##### `OntologyVersion.document`

```python
document
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.Entity`

```python
class emtellipro.db.schemas.legacy.models.Entity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table of entities stored in a specific document. The entity information is
stored in different tables depending on entity type. The `type_` column
can be used along with the `entity_id` to determine which exact entity is
referred to.

##### `Entity.id`

```python
id
```

**Value**: `Column(...)`

##### `Entity.type_`

```python
type_
```

**Value**: `Column(...)`

##### `Entity.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `Entity.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

##### `Entity.entity`

```python
property entity
```

The actual `*Entity` instance this relation references.

#### `emtellipro.db.schemas.legacy.models.AssumedEntity`

```python
class emtellipro.db.schemas.legacy.models.AssumedEntity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing assumed entities.

##### `AssumedEntity.id`

```python
id
```

**Value**: `Column(...)`

##### `AssumedEntity.value`

```python
value
```

**Value**: `Column(...)`

##### `AssumedEntity.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `AssumedEntity.document`

```python
document
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.FoundEntity`

```python
class emtellipro.db.schemas.legacy.models.FoundEntity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing found entities.

##### `FoundEntity.id`

```python
id
```

**Value**: `Column(...)`

##### `FoundEntity.polarity`

```python
polarity
```

**Value**: `Column(...)`

##### `FoundEntity.section_name`

```python
section_name
```

**Value**: `Column(...)`

##### `FoundEntity.uncertainty`

```python
uncertainty
```

**Value**: `Column(...)`

##### `FoundEntity.known_ambiguity`

```python
known_ambiguity
```

**Value**: `Column(...)`

##### `FoundEntity.question_status`

```python
question_status
```

**Value**: `Column(...)`

##### `FoundEntity.guidance`

```python
guidance
```

**Value**: `Column(...)`

##### `FoundEntity.experiencer`

```python
experiencer
```

**Value**: `Column(...)`

##### `FoundEntity.factuality`

```python
factuality
```

**Value**: `Column(...)`

##### `FoundEntity.heading_status`

```python
heading_status
```

**Value**: `Column(...)`

##### `FoundEntity.text`

```python
text
```

**Value**: `Column(...)`

##### `FoundEntity.start`

```python
start
```

**Value**: `Column(...)`

##### `FoundEntity.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `FoundEntity.document`

```python
document
```

**Value**: `relationship(...)`

##### `FoundEntity.concepts`

```python
concepts
```

**Value**: `relationship(...)`

##### `FoundEntity.locations`

```python
locations
```

**Value**: `relationship(...)`

##### `FoundEntity.spans`

```python
spans
```

**Value**: `relationship(...)`

##### `FoundEntity.type_names`

```python
type_names
```

**Value**: `relationship(...)`

##### `FoundEntity.measurement_units`

```python
measurement_units
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.FoundEntityMeasurementUnit`

```python
class emtellipro.db.schemas.legacy.models.FoundEntityMeasurementUnit
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing the measurement units for a found entity

##### `FoundEntityMeasurementUnit.id`

```python
id
```

**Value**: `Column(...)`

##### `FoundEntityMeasurementUnit.found_entity_id`

```python
found_entity_id
```

**Value**: `Column(...)`

##### `FoundEntityMeasurementUnit.text`

```python
text
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.FoundEntityType`

```python
class emtellipro.db.schemas.legacy.models.FoundEntityType
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing the type_name information from found entities.

Note that all 3 columns form the primary key since there is a unique type
name per ontology per found entity.

##### `FoundEntityType.found_entity_id`

```python
found_entity_id
```

**Value**: `Column(...)`

##### `FoundEntityType.ontology`

```python
ontology
```

**Value**: `Column(...)`

##### `FoundEntityType.type_name`

```python
type_name
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.Concept`

```python
class emtellipro.db.schemas.legacy.models.Concept
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing information about a specific column, with the primary keys
being the `concept_id` and `ontology`.

##### `Concept.concept_id`

```python
concept_id
```

**Value**: `Column(...)`

##### `Concept.ontology`

```python
ontology
```

**Value**: `Column(...)`

##### `Concept.description`

```python
description
```

**Value**: `Column(...)`

##### `Concept.documents`

```python
documents
```

**Value**: `relationship(...)`

##### `Concept.found_entities`

```python
found_entities
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.FoundEntitySpan`

```python
class emtellipro.db.schemas.legacy.models.FoundEntitySpan
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containging spans contained in found entities.

##### `FoundEntitySpan.id`

```python
id
```

**Value**: `Column(...)`

##### `FoundEntitySpan.start`

```python
start
```

**Value**: `Column(...)`

##### `FoundEntitySpan.end`

```python
end
```

**Value**: `Column(...)`

##### `FoundEntitySpan.text`

```python
text
```

**Value**: `Column(...)`

##### `FoundEntitySpan.found_entity_id`

```python
found_entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.SentenceLocation`

```python
class emtellipro.db.schemas.legacy.models.SentenceLocation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing sentence locations. It exists mainly as a link between the
locations table and the spans.

##### `SentenceLocation.id`

```python
id
```

**Value**: `Column(...)`

##### `SentenceLocation.text`

```python
text
```

**Value**: `Column(...)`

##### `SentenceLocation.spans`

```python
spans
```

**Value**: `relationship(...)`

##### `SentenceLocation.sections`

```python
sections
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.SentenceLocationSpan`

```python
class emtellipro.db.schemas.legacy.models.SentenceLocationSpan
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing sentence location spans

##### `SentenceLocationSpan.id`

```python
id
```

**Value**: `Column(...)`

##### `SentenceLocationSpan.start`

```python
start
```

**Value**: `Column(...)`

##### `SentenceLocationSpan.end`

```python
end
```

**Value**: `Column(...)`

##### `SentenceLocationSpan.sentence_location_id`

```python
sentence_location_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.HeadingLocation`

```python
class emtellipro.db.schemas.legacy.models.HeadingLocation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing heading locations. It exists mainly as a link between the
locations table and the spans.

##### `HeadingLocation.id`

```python
id
```

**Value**: `Column(...)`

##### `HeadingLocation.text`

```python
text
```

**Value**: `Column(...)`

##### `HeadingLocation.section_location_id`

```python
section_location_id
```

**Value**: `Column(...)`

##### `HeadingLocation.spans`

```python
spans
```

**Value**: `relationship(...)`

##### `HeadingLocation.section`

```python
section
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.HeadingLocationSpan`

```python
class emtellipro.db.schemas.legacy.models.HeadingLocationSpan
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing heading location spans

##### `HeadingLocationSpan.id`

```python
id
```

**Value**: `Column(...)`

##### `HeadingLocationSpan.start`

```python
start
```

**Value**: `Column(...)`

##### `HeadingLocationSpan.end`

```python
end
```

**Value**: `Column(...)`

##### `HeadingLocationSpan.heading_location_id`

```python
heading_location_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.PageLocation`

```python
class emtellipro.db.schemas.legacy.models.PageLocation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing page locations. It exists mainly as a link between the
locations table and the spans.

##### `PageLocation.id`

```python
id
```

**Value**: `Column(...)`

##### `PageLocation.text`

```python
text
```

**Value**: `Column(...)`

##### `PageLocation.page_index`

```python
page_index
```

**Value**: `Column(...)`

##### `PageLocation.spans`

```python
spans
```

**Value**: `relationship(...)`

##### `PageLocation.sections`

```python
sections
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.PageLocationSpan`

```python
class emtellipro.db.schemas.legacy.models.PageLocationSpan
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing page location spans

##### `PageLocationSpan.id`

```python
id
```

**Value**: `Column(...)`

##### `PageLocationSpan.start`

```python
start
```

**Value**: `Column(...)`

##### `PageLocationSpan.end`

```python
end
```

**Value**: `Column(...)`

##### `PageLocationSpan.page_location_id`

```python
page_location_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.PageSection`

```python
class emtellipro.db.schemas.legacy.models.PageSection
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing links between pages and section, with a composite primary
key of `page_id` and `section_id`.

##### `PageSection.page_id`

```python
page_id
```

**Value**: `Column(...)`

##### `PageSection.section_id`

```python
section_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.Relation`

```python
class emtellipro.db.schemas.legacy.models.Relation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing links to all the different kinds of relations. Use the
`type_` and `relation_id` fields to find the actual relation in one of
the other `*Relation` tables.

##### `Relation.id`

```python
id
```

**Value**: `Column(...)`

##### `Relation.type_`

```python
type_
```

**Value**: `Column(...)`

##### `Relation.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `Relation.relation_id`

```python
relation_id
```

**Value**: `Column(...)`

##### `Relation.relation`

```python
property relation
```

The actual `*Relation` instance this relation references.

#### `emtellipro.db.schemas.legacy.models.Location`

```python
class emtellipro.db.schemas.legacy.models.Location
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing links to all the different kinds of locations. Use the
`type_` and `location_id` fields to find the actual location in one of
the other `*Location` tables.

##### `Location.id`

```python
id
```

**Value**: `Column(...)`

##### `Location.type_`

```python
type_
```

**Value**: `Column(...)`

##### `Location.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `Location.location_id`

```python
location_id
```

**Value**: `Column(...)`

##### `Location.location`

```python
property location
```

The actual `*Location` instance this relation references.

#### `emtellipro.db.schemas.legacy.models.SectionLocationSpan`

```python
class emtellipro.db.schemas.legacy.models.SectionLocationSpan
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing sentence location span information.

##### `SectionLocationSpan.id`

```python
id
```

**Value**: `Column(...)`

##### `SectionLocationSpan.start`

```python
start
```

**Value**: `Column(...)`

##### `SectionLocationSpan.end`

```python
end
```

**Value**: `Column(...)`

##### `SectionLocationSpan.section_location_id`

```python
section_location_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ImageLinkRelation`

```python
class emtellipro.db.schemas.legacy.models.ImageLinkRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing image link relation information.

##### `ImageLinkRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `ImageLinkRelation.image_findings`

```python
image_findings
```

**Value**: `relationship(...)`

##### `ImageLinkRelation.references`

```python
references
```

**Value**: `relationship(...)`

##### `ImageLinkRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.FollowupRelation`

```python
class emtellipro.db.schemas.legacy.models.FollowupRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containign follow-up relation information.

##### `FollowupRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `FollowupRelation.polarity`

```python
polarity
```

**Value**: `Column(...)`

##### `FollowupRelation.time_expression_id`

```python
time_expression_id
```

**Value**: `Column(...)`

##### `FollowupRelation.time_expression`

```python
time_expression
```

**Value**: `relationship(...)`

##### `FollowupRelation.procedures`

```python
procedures
```

**Value**: `relationship(...)`

##### `FollowupRelation.reasons`

```python
reasons
```

**Value**: `relationship(...)`

##### `FollowupRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ExperiencerRelation`

```python
class emtellipro.db.schemas.legacy.models.ExperiencerRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing experience relation information.

##### `ExperiencerRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `ExperiencerRelation.polarity`

```python
polarity
```

**Value**: `Column(...)`

##### `ExperiencerRelation.experiencer_id`

```python
experiencer_id
```

**Value**: `Column(...)`

##### `ExperiencerRelation.experienced_id`

```python
experienced_id
```

**Value**: `Column(...)`

##### `ExperiencerRelation.experiencer`

```python
experiencer
```

**Value**: `relationship(...)`

##### `ExperiencerRelation.experienced`

```python
experienced
```

**Value**: `relationship(...)`

##### `ExperiencerRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MeasurementRelation`

```python
class emtellipro.db.schemas.legacy.models.MeasurementRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing measurement relations.

##### `MeasurementRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `MeasurementRelation.subject_id`

```python
subject_id
```

**Value**: `Column(...)`

##### `MeasurementRelation.value_id`

```python
value_id
```

**Value**: `Column(...)`

##### `MeasurementRelation.subject`

```python
subject
```

**Value**: `relationship(...)`

##### `MeasurementRelation.value`

```python
value
```

**Value**: `relationship(...)`

##### `MeasurementRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.QualifierRelation`

```python
class emtellipro.db.schemas.legacy.models.QualifierRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing qualifier relations.

##### `QualifierRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `QualifierRelation.qualifier_type`

```python
qualifier_type
```

**Value**: `Column(...)`

##### `QualifierRelation.qualifier_id`

```python
qualifier_id
```

**Value**: `Column(...)`

##### `QualifierRelation.qualifies_id`

```python
qualifies_id
```

**Value**: `Column(...)`

##### `QualifierRelation.qualifier`

```python
qualifier
```

**Value**: `relationship(...)`

##### `QualifierRelation.qualifies`

```python
qualifies
```

**Value**: `relationship(...)`

##### `QualifierRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelation`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing medication relations.

##### `MedicationRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelation.drug_entity_id`

```python
drug_entity_id
```

**Value**: `Column(...)`

##### `MedicationRelation.drug`

```python
drug
```

**Value**: `relationship(...)`

##### `MedicationRelation.dosages`

```python
dosages
```

**Value**: `relationship(...)`

##### `MedicationRelation.frequencies`

```python
frequencies
```

**Value**: `relationship(...)`

##### `MedicationRelation.modes`

```python
modes
```

**Value**: `relationship(...)`

##### `MedicationRelation.quantities`

```python
quantities
```

**Value**: `relationship(...)`

##### `MedicationRelation.routes`

```python
routes
```

**Value**: `relationship(...)`

##### `MedicationRelation.necessities`

```python
necessities
```

**Value**: `relationship(...)`

##### `MedicationRelation.modifiers`

```python
modifiers
```

**Value**: `relationship(...)`

##### `MedicationRelation.durations`

```python
durations
```

**Value**: `relationship(...)`

##### `MedicationRelation.indications`

```python
indications
```

**Value**: `relationship(...)`

##### `MedicationRelation.date_times`

```python
date_times
```

**Value**: `relationship(...)`

##### `MedicationRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.TemporalityRelation`

```python
class emtellipro.db.schemas.legacy.models.TemporalityRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing temporality relations.

##### `TemporalityRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `TemporalityRelation.polarity`

```python
polarity
```

**Value**: `Column(...)`

##### `TemporalityRelation.category`

```python
category
```

**Value**: `Column(...)`

##### `TemporalityRelation.temporal_entity_id`

```python
temporal_entity_id
```

**Value**: `Column(...)`

##### `TemporalityRelation.subject_id`

```python
subject_id
```

**Value**: `Column(...)`

##### `TemporalityRelation.temporal_entity`

```python
temporal_entity
```

**Value**: `relationship(...)`

##### `TemporalityRelation.subject`

```python
subject
```

**Value**: `relationship(...)`

##### `TemporalityRelation.modifiers`

```python
modifiers
```

**Value**: `relationship(...)`

##### `TemporalityRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ReportedEventRelation`

```python
class emtellipro.db.schemas.legacy.models.ReportedEventRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing reported event relations.

##### `ReportedEventRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `ReportedEventRelation.polarity`

```python
polarity
```

**Value**: `Column(...)`

##### `ReportedEventRelation.category`

```python
category
```

**Value**: `Column(...)`

##### `ReportedEventRelation.subject_id`

```python
subject_id
```

**Value**: `Column(...)`

##### `ReportedEventRelation.subject`

```python
subject
```

**Value**: `relationship(...)`

##### `ReportedEventRelation.to_entities`

```python
to_entities
```

**Value**: `relationship(...)`

##### `ReportedEventRelation.from_entities`

```python
from_entities
```

**Value**: `relationship(...)`

##### `ReportedEventRelation.methods`

```python
methods
```

**Value**: `relationship(...)`

##### `ReportedEventRelation.time_expressions`

```python
time_expressions
```

**Value**: `relationship(...)`

##### `ReportedEventRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.AnatomicSiteRelation`

```python
class emtellipro.db.schemas.legacy.models.AnatomicSiteRelation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing anatomic site relations.

##### `AnatomicSiteRelation.id`

```python
id
```

**Value**: `Column(...)`

##### `AnatomicSiteRelation.site_id`

```python
site_id
```

**Value**: `Column(...)`

##### `AnatomicSiteRelation.situated_entity_id`

```python
situated_entity_id
```

**Value**: `Column(...)`

##### `AnatomicSiteRelation.site`

```python
site
```

**Value**: `relationship(...)`

##### `AnatomicSiteRelation.situated_entity`

```python
situated_entity
```

**Value**: `relationship(...)`

##### `AnatomicSiteRelation.confidence`

```python
confidence
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.SectionLocation`

```python
class emtellipro.db.schemas.legacy.models.SectionLocation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containg section locations.

##### `SectionLocation.id`

```python
id
```

**Value**: `Column(...)`

##### `SectionLocation.name`

```python
name
```

**Value**: `Column(...)`

##### `SectionLocation.level`

```python
level
```

**Value**: `Column(...)`

##### `SectionLocation.parent_id`

```python
parent_id
```

**Value**: `Column(...)`

##### `SectionLocation.text`

```python
text
```

**Value**: `Column(...)`

##### `SectionLocation.children`

```python
children
```

**Value**: `relationship(...)`

##### `SectionLocation.spans`

```python
spans
```

**Value**: `relationship(...)`

##### `SectionLocation.pages`

```python
pages
```

**Value**: `relationship(...)`

##### `SectionLocation.sentences`

```python
sentences
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.SentenceSection`

```python
class emtellipro.db.schemas.legacy.models.SentenceSection
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Table containing links between sentences and section, with a composite
primary key of `sentence_id` and `section_id`.

##### `SentenceSection.sentence_id`

```python
sentence_id
```

**Value**: `Column(...)`

##### `SentenceSection.section_id`

```python
section_id
```

**Value**: `Column(...)`

##### `SentenceSection.sentence`

```python
sentence
```

**Value**: `relationship(...)`

##### `SentenceSection.section`

```python
section
```

**Value**: `relationship(...)`

#### `emtellipro.db.schemas.legacy.models.DocumentConcept`

```python
class emtellipro.db.schemas.legacy.models.DocumentConcept
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking documents to concepts.

##### `DocumentConcept.document_id`

```python
document_id
```

**Value**: `Column(...)`

##### `DocumentConcept.concept_id`

```python
concept_id
```

**Value**: `Column(...)`

##### `DocumentConcept.concept_ontology`

```python
concept_ontology
```

**Value**: `Column(...)`

##### `DocumentConcept.__table_args__`

```python
__table_args__
```

**Value**: `()`

#### `emtellipro.db.schemas.legacy.models.FoundEntityConcept`

```python
class emtellipro.db.schemas.legacy.models.FoundEntityConcept
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking found entities to concepts.

##### `FoundEntityConcept.found_entity_id`

```python
found_entity_id
```

**Value**: `Column(...)`

##### `FoundEntityConcept.concept_id`

```python
concept_id
```

**Value**: `Column(...)`

##### `FoundEntityConcept.concept_ontology`

```python
concept_ontology
```

**Value**: `Column(...)`

##### `FoundEntityConcept.confidence`

```python
confidence
```

**Value**: `Column(...)`

##### `FoundEntityConcept.__table_args__`

```python
__table_args__
```

**Value**: `()`

#### `emtellipro.db.schemas.legacy.models.FoundEntityLocation`

```python
class emtellipro.db.schemas.legacy.models.FoundEntityLocation
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking found entities to locations.

##### `FoundEntityLocation.found_entity_id`

```python
found_entity_id
```

**Value**: `Column(...)`

##### `FoundEntityLocation.location_id`

```python
location_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ImageLinkRelationImageFinding`

```python
class emtellipro.db.schemas.legacy.models.ImageLinkRelationImageFinding
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking image link relations to entities specified as
image findings.

##### `ImageLinkRelationImageFinding.imagelink_id`

```python
imagelink_id
```

**Value**: `Column(...)`

##### `ImageLinkRelationImageFinding.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ImageLinkRelationReference`

```python
class emtellipro.db.schemas.legacy.models.ImageLinkRelationReference
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking image link relations to entities specified as
references.

##### `ImageLinkRelationReference.imagelink_id`

```python
imagelink_id
```

**Value**: `Column(...)`

##### `ImageLinkRelationReference.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.FollowupRelationProcedure`

```python
class emtellipro.db.schemas.legacy.models.FollowupRelationProcedure
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking followup relations to entities specified as
procedures.

##### `FollowupRelationProcedure.followup_id`

```python
followup_id
```

**Value**: `Column(...)`

##### `FollowupRelationProcedure.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.FollowupRelationReason`

```python
class emtellipro.db.schemas.legacy.models.FollowupRelationReason
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking followup relations to entities specified as
reasons.

##### `FollowupRelationReason.followup_id`

```python
followup_id
```

**Value**: `Column(...)`

##### `FollowupRelationReason.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationDosage`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationDosage
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
dosage

##### `MedicationRelationDosage.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationDosage.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationDosage.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationFrequency`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationFrequency
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
frequency

##### `MedicationRelationFrequency.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationFrequency.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationFrequency.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationMode`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationMode
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
mode

##### `MedicationRelationMode.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationMode.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationMode.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationQuantity`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationQuantity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
quantity

##### `MedicationRelationQuantity.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationQuantity.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationQuantity.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationRoute`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationRoute
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
route

##### `MedicationRelationRoute.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationRoute.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationRoute.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationNecessity`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationNecessity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
route

##### `MedicationRelationNecessity.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationNecessity.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationNecessity.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationModifier`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationModifier
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
route

##### `MedicationRelationModifier.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationModifier.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationModifier.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationDuration`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationDuration
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
duration

##### `MedicationRelationDuration.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationDuration.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationDuration.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationIndication`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationIndication
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
indication

##### `MedicationRelationIndication.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationIndication.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationIndication.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.MedicationRelationDatetime`

```python
class emtellipro.db.schemas.legacy.models.MedicationRelationDatetime
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking medication relations to entities specified as
datetimes.

##### `MedicationRelationDatetime.id`

```python
id
```

**Value**: `Column(...)`

##### `MedicationRelationDatetime.medication_id`

```python
medication_id
```

**Value**: `Column(...)`

##### `MedicationRelationDatetime.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.TemporalityRelationModifier`

```python
class emtellipro.db.schemas.legacy.models.TemporalityRelationModifier
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking temporality relations to entities specified as
modifiers

##### `TemporalityRelationModifier.id`

```python
id
```

**Value**: `Column(...)`

##### `TemporalityRelationModifier.temporality_id`

```python
temporality_id
```

**Value**: `Column(...)`

##### `TemporalityRelationModifier.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ReportedEventRelationToEntity`

```python
class emtellipro.db.schemas.legacy.models.ReportedEventRelationToEntity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking reported-event relations to entities which were
recipients of the communication.

##### `ReportedEventRelationToEntity.reported_event_id`

```python
reported_event_id
```

**Value**: `Column(...)`

##### `ReportedEventRelationToEntity.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ReportedEventRelationFromEntity`

```python
class emtellipro.db.schemas.legacy.models.ReportedEventRelationFromEntity
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking reported-event relations to entities which were
sources of the communication.

##### `ReportedEventRelationFromEntity.reported_event_id`

```python
reported_event_id
```

**Value**: `Column(...)`

##### `ReportedEventRelationFromEntity.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ReportedEventRelationMethod`

```python
class emtellipro.db.schemas.legacy.models.ReportedEventRelationMethod
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking reported-event relations to entities which were
the methods of communication

##### `ReportedEventRelationMethod.reported_event_id`

```python
reported_event_id
```

**Value**: `Column(...)`

##### `ReportedEventRelationMethod.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.ReportedEventRelationTimeExpression`

```python
class emtellipro.db.schemas.legacy.models.ReportedEventRelationTimeExpression
```

**Bases:** [`Base`](/nlp/python/reference/db-schemas-legacy-models#emtelliprodbschemaslegacymodelsbase)

**Bases**: `emtellipro.db.schemas.legacy.models.Base`

Association table linking reported-event relations to entities which were
the time expressions that indicate when the communication took place

##### `ReportedEventRelationTimeExpression.reported_event_id`

```python
reported_event_id
```

**Value**: `Column(...)`

##### `ReportedEventRelationTimeExpression.entity_id`

```python
entity_id
```

**Value**: `Column(...)`

#### `emtellipro.db.schemas.legacy.models.recreate_indexes`

```python
emtellipro.db.schemas.legacy.models.recreate_indexes(connection)
```

Re-create all the full text search indexes.

This is normally executed by the migrate and create-db commands

**Parameters:**

**`connection`**

this is an SQLAlchemy connection object

---

**Returns:**

number of indexes created