Skip to content

Commit

Permalink
feat(docs): minor edits to docs (#69)
Browse files Browse the repository at this point in the history
- platform -> OS
- workspace -> folder
- Normalize capitalization of data hub, compute hub, workstation, Python
- Lint: removed trailing spaces and consecutive blank lines in docs
  • Loading branch information
jonrkarr authored Aug 9, 2024
1 parent 6b67284 commit ced08a1
Show file tree
Hide file tree
Showing 17 changed files with 107 additions and 133 deletions.
8 changes: 4 additions & 4 deletions docs/compute-hub/index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Compute Hub
# Compute hub

The Deep Origin Compute Hub allows you create and use powerful workstations that come with pre-installed software packages. Deep Origin was built to help computational scientists get clean data from their labs and perform advanced analyses and simulations.
The Deep Origin compute hub allows you create and use powerful workstations with pre-installed software packages. Deep Origin was built to help computational scientists get clean data from their labs and perform advanced analyses and simulations.

Every Deep Origin Workstation comes pre-installed and pre-configured with this python client and CLI.
Each Deep Origin workstation comes pre-installed and pre-configured with this Python client and CLI.

Read more about the Compute Hub [here :octicons-link-external-16:](https://docs.deeporigin.io/docs/os/compute-hub).
Learn more about the compute hub [here :octicons-link-external-16:](https://docs.deeporigin.io/docs/os/compute-hub).
2 changes: 1 addition & 1 deletion docs/configure.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ To view the configuration for this package, run:
deeporigin config show
```

This will display a table like below:
This will display a table such as below:

```
╭─────────────────────────────┬─────────────────────────────────────╮
Expand Down
26 changes: 12 additions & 14 deletions docs/data-hub/index.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
# Data Hub
# Data hub

The Deep Origin data hub provides R&D teams a foundation for collaboratively capturing data, extracting insights, and making decisions:

- Databases for capturing rows of data, metadata, and procedures.
- Customizable columns for capturing structured information such as the age and genotype of a sample.
- Notebooks such as for common protocols and recording experiments.
- File columns and notebook attachments for capturing files such as the results of experiments.
- Reference columns and notebook mentions for capturing relationships, such as the chemical, RNA, antibody, or cell line that an assay characterized.
- Folders for hierarchically organizing data, such as by project, team, or experimental modality.
- Column and file viewers such as for visualizing the sequence of a plasmid or the structure of a chemical or protein.
- Chart studio for interactively analyzing columnar data.
- AI assistant for interactively analyze and visualize data.
- Advanced computational analysis with workflows and workstations.
- Process flows and automations for streamlining data processing, decision-making, and project management.
- **Databases** for capturing rows of data, metadata, and procedures.
- Customizable columns for capturing structured information such as the age and genotype of a sample.
- **Notebooks** such as for common protocols and recording experiments.
- File columns and notebook attachments for capturing files such as the results of experiments.
- Reference columns and notebook mentions for capturing relationships, such as the chemical, RNA, antibody, or cell line that an assay characterized.
- **Folders** for hierarchically organizing data, such as by project, team, or experimental modality.
- **Column and file viewers** such as for visualizing the sequence of a plasmid or the structure of a chemical or protein.
- **Chart studio** for interactively analyzing columnar data.
- **AI assistant** for interactively analyze and visualize data.
- **Process flows and automations** for streamlining data processing, decision-making, and project management.


Read more about the Data Hub [here :octicons-link-external-16:](https://docs.deeporigin.io/docs/os/data-hub).
Learn more about the data hub [here :octicons-link-external-16:](https://docs.deeporigin.io/docs/os/data-hub).
12 changes: 5 additions & 7 deletions docs/how-to/auth.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,12 @@ To use most of the functionality of the CLI or Python client, you must first run

In either case, you will be presented with a prompt similar to below:

```
To connect to the Deep Origin platform, navigate your browser to
```shell
To connect to the Deep Origin OS, navigate your browser to

https://<env>auth0.com/activate?user_code=VMPZ-PQFG

and verify the confirmation code is "VMPZ-PQFG", and click the "Confirm" button.
```

When you visit that URL, you will see a prompt that looks like:
Expand All @@ -38,9 +37,8 @@ After signing in, your access tokens will be cached to disk and then automatical
be used in subsequent interactions with Deep Origin.

!!! info "Authenticating"
In most cases, you only need to authenticate to the Deep Origin platform once.
In most cases, you only need to authenticate to the Deep Origin OS once.
You do not need to authenticate every time you use the client or the CLI.


!!! question "Authenticating on Deep Origin Workstations"
Automatic authentication is currently being worked on on Deep Origin Workstations. Presently, you will still have to authenticate (once) manually on Deep Origin Workstations.
!!! question "Authenticating on Deep Origin workstations"
Presently, workstation users must authenticate (once) to the Deep Origin OS. We plan to develop the capability to automatically authenticate workstation users.
24 changes: 8 additions & 16 deletions docs/how-to/data-hub/create.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
This document describes how to create databases, columns in databases, and folders in the Deep Origin Data Hub.

This document describes how to create databases, columns in databases, and folders (workspaces) in the Deep Origin data hub.

## Folders

Folders (or workspaces) can be created by specifying a name, and, optionally, a parent.
Folders can be created by specifying a name, and, optionally, a parent.

=== "CLI"

Expand All @@ -26,26 +25,25 @@ Folders (or workspaces) can be created by specifying a name, and, optionally, a

```py
from deeporigin.data_hub import api
api.create_workspace(name="test-workspace")
api.create_workspace(name="test-folder")
```

To create a folder within another folder, specify the parent:


```py
api.create_workspace(
name="test-workspace-2",
name="test-folder-2",
parent_id="parent-id",
)
```

## Databases

Databases can be created by specifying a name, and, optionally, a parent.
Databases can be created by specifying a name, and, optionally, a parent.

=== "CLI"


If no parent is specified, the database will be created at the root level.

```bash
Expand Down Expand Up @@ -78,29 +76,24 @@ Databases can be created by specifying a name, and, optionally, a parent.
)
```


## Database columns

!!! warning "Work in progress"
There is limited support for creating database columns from the python client and CLI at this time. Not all features are supported yet.

Currently, this package has limited support for creating database columns. We plan to expand the capabilities of this package.

Create a new database column in an existing database using:
To create a new database column in an existing database, run:

=== "CLI"


```bash
deeporigin data new column \
--name <name> \
--database <database-id> \
--type <type>
```


=== "Python"


```py
from deeporigin.data_hub import api
api.add_database_column(
Expand All @@ -111,5 +104,4 @@ Create a new database column in an existing database using:
)
```


This code creates a new column in that database. To configure the type of the column, use the `type` argument. The type must be one of [DataType](../../ref/data-hub/types.md#src.utils.DataType).
This code creates a new column in the existing database. To configure the type of the column, use the `type` argument. The type must a member of [DataType](../../ref/data-hub/types.md#src.utils.DataType).
47 changes: 15 additions & 32 deletions docs/how-to/data-hub/delete.md
Original file line number Diff line number Diff line change
@@ -1,74 +1,57 @@
This document describes how to delete
This document describes how to delete objects in the Deep Origin data hub:

- database rows
- database columns
- databases and
- folders

in the Deep Origin Data Hub.
- Database rows
- Database columns
- Databases
- Folders (workspaces)

!!! danger "Exercise caution"
- Deleting a workspace deletes all databases inside it.
- Deleting a column destroys all data in that column, including all files assigned to cells in that column.
- Deleting a database deletes all rows inside it.
- Deleting a folder deletes all of the databases in the folder.
- Deleting a column destroys all of the data in that column, including all of the files assigned to the cells in that column.
- Deleting a database deletes all of the rows in the database.

All resources will be deleted without asking for confirmation.

## Delete database rows, databases, and folders

=== "CLI"
To delete multiple rows, databases and folders, run:

Multiple rows, databases and folders can be deleted using:
=== "CLI"

```bash
deeporigin data delete --ids <ids>
```



=== "Python"



```py
from deeporigin.data_hub import api
api.delete_rows(row_ids=["row-1","database-1","workspace-1"])
api.delete_rows(row_ids=["row-1","database-1","folder-1"])
```

!!! Info "Rows?"
Rows, workspaces and databases can all be deleted using the `delete_rows` method.


Rows, folders and databases can all be deleted using the `delete_rows` method.

## Delete database columns


## Delete database columns

Columns in databases can be deleted using:
To delete columns in databases, run:

=== "CLI"



```bash
deeporigin data delete --ids <ids> --columns
```

!!! warning "Column IDs"
Currently, columns can only be deleted using Column IDs, which are not the same as column names. To view the column IDs of a database, use
Currently, columns can only be deleted using their IDs, which are distinct from their names. To view the IDs of the columns of a database, run:

```bash
deeporigin data describe <database-id>
```



=== "Python"



```py
from deeporigin.data_hub import api
api.delete_database_column(column_id="col-id")
```

2 changes: 1 addition & 1 deletion docs/how-to/data-hub/list-data.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

This page describes how to list resources on Deep Origin.
Listing folders, databases, rows and files can be used
Listing folders (workspaces), databases, rows and files can be used
to discover the resources available on Deep Origin, and show
their IDs for further queries.

Expand Down
6 changes: 3 additions & 3 deletions docs/how-to/variables.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Install variables and secrets

[Variables and secrets](https://docs.deeporigin.io/docs/os/variables-secrets) specified in the Deep Orgin platform, either
[Variables and secrets](https://docs.deeporigin.io/docs/os/variables-secrets) captured in the Deep Orgin OS, either
at the organization level or the account level, can be installed into
workstations by running the following command:

Expand All @@ -18,5 +18,5 @@ No variables were deleted
EnvironmentVariable: foo
```

!!! info "Only on Deep Origin Workstations"
This function of the CLI only works on Deep Origin Workstations. This will not work on your local computer.
!!! info "Only on Deep Origin workstations"
This function of the CLI only works on Deep Origin workstations. This function will not work on your local computer.
4 changes: 2 additions & 2 deletions mkdocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ nav:
- Install: install.md
- Configure: configure.md
- Authenticate: how-to/auth.md
- Data Hub:
- Data hub:
- data-hub/index.md
- How to:
- Create objects: how-to/data-hub/create.md
Expand All @@ -55,7 +55,7 @@ nav:
- High-level API: ref/data-hub/high-level-api.md
- Low-level API: ref/data-hub/low-level-api.md
- Types and constants: ref/data-hub/types.md
- Compute Hub:
- Compute hub:
- compute-hub/index.md
- How to:
- Install variables and secrets: how-to/variables.md
Expand Down
4 changes: 2 additions & 2 deletions src/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def authenticate() -> dict:
# Prompt the user to sign into the Deep Origin platform
print(
(
"To connect to the Deep Origin platform, "
"To connect to the Deep Origin OS, "
f"navigate your browser to \n\n{verification_url}\n\n"
f'and verify the confirmation code is "{user_code}", '
'and click the "Confirm" button.'
Expand Down Expand Up @@ -171,7 +171,7 @@ def authenticate() -> dict:


def refresh_tokens(api_refresh_token: str) -> str:
"""Refresh the access token for the DO platform
"""Refresh the access token for the Deep Origin OS
Args:
api_refresh_token (:obj:`str`): API refresh token
Expand Down
Loading

0 comments on commit ced08a1

Please sign in to comment.