---
# System prepended metadata

title: Source Record Mapping
tags: [' data', isamples, ' source', ' mapping']

---

---
title: Source Record Mapping
tags: isamples, data, source, mapping
---

# Source Record Mapping

Process for ingest of source records into iSamples.

In general the process is:

```plantuml
@startuml
skinparam monochrome true
:Source;
-> load;
:isb_thing
[postgres];
-> transform;
:isb_index 
[solr];
@enduml
```


## GEOME

| Command | Description |
| --- | --- |
| git status | List all new or modified files |
| git diff | Show file differences that haven't been staged |


---


The general conceptual structure of sample records

```graphviz
digraph G {
  node[shape=record, height=.3]
  event [label="{Event|ID|time|location}"]
  sample [label="{Sample|ID|event}"]
  tissue [label="{Tissue|ID|sample}"]
  expedition [color=gray, fontcolor=gray]
  project [color=gray, fontcolor=gray]
  photo [color=gray, fontcolor=gray]
  person [color=gray, fontcolor=gray]
  expedition -> project [label="isPartOf"]
  event -> expedition [label="isPartOf"]
  sample -> event
  tissue -> sample
  photo -> sample
  photo -> tissue
  photo -> event
  photo -> expedition
}
```

## SESAR

Retrieving records and persisting to ISB. Each retrieved record is complete representation of sample though may reference other records as parent or child.

```plantuml
@startuml
skinparam monochrome true
repeat :sitemap.xml;
  :IGSN;
  note right
  IGSN value extracted from sitemap loc
  end note 
  :JSON-LD;
  note right
  api.geosamples.org/v1/sample/igsn-ev-json-ld/igsn
  end note
  :isb_thing;
  note right
    The JSON-LD is persisted as 
    JSON in the record.
  end note
repeat while (more records?) is (yes)
@enduml
```

Generate index record
```plantuml
@startuml
skinparam monochrome true
:isb_thing;
-> SESARTransformer ;
:core record;
:isb_index;
@enduml
```

## GEOME



## OpenContext

## Smithsonian