Skip to content

Commit

Permalink
renamed allbase to ark.
Browse files Browse the repository at this point in the history
  • Loading branch information
TimothyStiles committed Apr 4, 2023
1 parent fbd0fd5 commit 03e6f3b
Show file tree
Hide file tree
Showing 25 changed files with 89 additions and 90 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.166.1/containers/ubuntu
{
"name": "allbase - Ubuntu",
"name": "ark - Ubuntu",
"build": {
"dockerfile": "Dockerfile",
// Update 'VARIANT' to pick an Ubuntu version: focal, bionic
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
allbase.db
ark.db
.DS_Store
data/rhea.rdf.gz
cmd/main
34 changes: 17 additions & 17 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# Introduction

Yo, what up! if you're reading this then I'm super psyched because that means that you're thinking about contributing to Allbase! Thanks so much for your time and consideration. It's rad people like you that make Allbase such a cool computational synthetic biology tool.
Yo, what up! if you're reading this then I'm super psyched because that means that you're thinking about contributing to ark! Thanks so much for your time and consideration. It's rad people like you that make ark such a cool computational synthetic biology tool.

I wrote this contributor's guide to help newcomers feel welcome. Getting started with a new project can be complicated and I wanted to make it as easy as possible for you to contribute and as easy as possible for me to help.

Currently any sincere pull request is a good request.
Allbase is still in pre-release so there are so many way to contribute!
ark is still in pre-release so there are so many way to contribute!
Here's a list of ideas but feel free to suggest anything I may have forgotten to include.

* Feature requests - especially cool new algorithms with citations.
Expand All @@ -17,7 +17,7 @@ Here's a list of ideas but feel free to suggest anything I may have forgotten to
* Bug triaging.
* Community management.
* Art! Dreams! Your excellence!
* Code that can be pulled into Allbase itself.
* Code that can be pulled into ark itself.

# Contributor guidelines
### Excellence, and the contributor's code of conduct
Expand All @@ -32,11 +32,11 @@ First up, most importantly we have a contributor's code of conduct. For some rea

### Do-ocracy

Allbase runs on do-ocracy. Do-ocracy is a simple concept. If you don't like something you don't need permission to fix it, you can just go ahead and fix it! If you actually want to merge your fix, or contribute in someway that benefits everybody, it'd really, really, really help if you got some light consensus from the rest of the Allbase development community but hey, if you really need to do something then you just gotta do it! Just don't expect me to merge it if it doesn't meet our technical criteria or isn't quite right for Allbase.
ark runs on do-ocracy. Do-ocracy is a simple concept. If you don't like something you don't need permission to fix it, you can just go ahead and fix it! If you actually want to merge your fix, or contribute in someway that benefits everybody, it'd really, really, really help if you got some light consensus from the rest of the ark development community but hey, if you really need to do something then you just gotta do it! Just don't expect me to merge it if it doesn't meet our technical criteria or isn't quite right for ark.

### Technical requirements

Part of what makes Allbase so special is that we have standards. DNA is already spaghetti code on its own and we just don't need to add to that.
Part of what makes ark so special is that we have standards. DNA is already spaghetti code on its own and we just don't need to add to that.

All successfully merged pull requests must meet the following criteria:

Expand All @@ -54,19 +54,19 @@ Don't worry if you submit a pull request and all the tests break and the code is

### Be welcoming

As one final guideline please be welcoming to newcomers and encourage new contributors from all walks of life. I want Allbase to be for everyone and that includes you and people who don't look, sound, or act like you!
As one final guideline please be welcoming to newcomers and encourage new contributors from all walks of life. I want ark to be for everyone and that includes you and people who don't look, sound, or act like you!

# Your first contribution

Unsure where to begin contributing to Allbase? You can start by looking through these beginner and help-wanted issues:
Unsure where to begin contributing to ark? You can start by looking through these beginner and help-wanted issues:

[Beginner issues](https://github.com/TimothyStiles/allbase/issues?q=is%3Aissue+is%3Aopen+label%3A%22beginner%22+) - issues which should only require a few lines of code, and a test or two.
[Beginner issues](https://github.com/TimothyStiles/ark/issues?q=is%3Aissue+is%3Aopen+label%3A%22beginner%22+) - issues which should only require a few lines of code, and a test or two.

[Good first issues](https://github.com/TimothyStiles/allbase/contribute) - issues which are good for first time contributors.
[Good first issues](https://github.com/TimothyStiles/ark/contribute) - issues which are good for first time contributors.

[Help wanted issues](https://github.com/TimothyStiles/allbase/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted%22+) - issues which should be a bit more involved than beginner issues.
[Help wanted issues](https://github.com/TimothyStiles/ark/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted%22+) - issues which should be a bit more involved than beginner issues.

[Feature requests](https://github.com/TimothyStiles/allbase/labels/enhancement) - before requesting a new feature search through previous feature requests to see if it's already been requested. If not then feel free to submit a request and tag it with the enhancement tag!
[Feature requests](https://github.com/TimothyStiles/ark/labels/enhancement) - before requesting a new feature search through previous feature requests to see if it's already been requested. If not then feel free to submit a request and tag it with the enhancement tag!

### Working on your first Pull Request?

Expand All @@ -87,11 +87,11 @@ For something that is bigger than a one or two line fix:

## Virtual Environments and Development Containers

In order to simplify the development experience, and environment setup, the allbase Github repository comes packaged to support *Github CodeSpaces* and [*VSCode Development Containers*](https://code.visualstudio.com/docs/remote/containers#_getting-started). *Github CodeSpaces* will give you ability to spin up a Github hosted instance of Ubuntu that would allow you run, test, develop allbase from the browser. *VSCode Development Containers* in turn will allow your installation of VSCode to spin up a docker instance of Ubuntu on your computer and automatically mount your code onto it so that you continue developing on this docker instance that has all the required development environment setup.
In order to simplify the development experience, and environment setup, the ark Github repository comes packaged to support *Github CodeSpaces* and [*VSCode Development Containers*](https://code.visualstudio.com/docs/remote/containers#_getting-started). *Github CodeSpaces* will give you ability to spin up a Github hosted instance of Ubuntu that would allow you run, test, develop ark from the browser. *VSCode Development Containers* in turn will allow your installation of VSCode to spin up a docker instance of Ubuntu on your computer and automatically mount your code onto it so that you continue developing on this docker instance that has all the required development environment setup.

## Recommended Plugins

Whether you're a beginner with Go or you're an experienced developer, You should see the suggestions popup automatically when you goto the *Plugins* tab in VSCode. Using these plugins can help accelerate the development experience and also allow you to work more collaboratively with other allbase developers.
Whether you're a beginner with Go or you're an experienced developer, You should see the suggestions popup automatically when you goto the *Plugins* tab in VSCode. Using these plugins can help accelerate the development experience and also allow you to work more collaboratively with other ark developers.

# How to report a bug

Expand All @@ -108,16 +108,16 @@ If the answer to either of those two questions are "yes", then you're probably d

### Non-security related bugs

For non-security bug reports please [submit it using this template!](https://github.com/TimothyStiles/allbase/issues/new?assignees=&labels=&template=bug_report.md&title=)
For non-security bug reports please [submit it using this template!](https://github.com/TimothyStiles/ark/issues/new?assignees=&labels=&template=bug_report.md&title=)

# How to suggest a feature or enhancement

If you want to suggest a feature it's as easy as filling out this [issue template](https://github.com/TimothyStiles/allbase/issues/new?assignees=&labels=&template=feature_request.md&title=), but before you do please [check to see if it's already been suggested!](https://github.com/TimothyStiles/allbase/labels/enhancement)
If you want to suggest a feature it's as easy as filling out this [issue template](https://github.com/TimothyStiles/ark/issues/new?assignees=&labels=&template=feature_request.md&title=), but before you do please [check to see if it's already been suggested!](https://github.com/TimothyStiles/ark/labels/enhancement)

# How add a recommended VSCode Plugin

Allbase comes with a set of recommended plugins for VSCode. If you have suggestions that will simplify life for the allbase dev community, consider doing a pull-request after modifying `.vscode/extensions.json`.
ark comes with a set of recommended plugins for VSCode. If you have suggestions that will simplify life for the ark dev community, consider doing a pull-request after modifying `.vscode/extensions.json`.

# In closing

Thanks, for reading and I'm super psyched to see what you'll do with Allbase!
Thanks, for reading and I'm super psyched to see what you'll do with ark!
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
# Allbase
# ark

## Allbase is a database for engineering organisms
## ark is a database for engineering organisms

* **Comprehensive:** Allbase is a single service that can search, store, and cross reference sequences and pathways from genbank, rhea, chembl, and uniprot
* **Comprehensive:** ark is a single service that can search, store, and cross reference sequences and pathways from genbank, rhea, chembl, and uniprot

* **Modern:** Allbase serves JSON and is written in Go. Allbase parses legacy file formats so you don't have to.
* **Modern:** ark serves JSON and is written in Go. ark parses legacy file formats so you don't have to.

* **Stable (soon):** Allbase will be well tested and designed to be used in industrial, academic, and hobbyist settings
* **Stable (soon):** ark will be well tested and designed to be used in industrial, academic, and hobbyist settings

## Install

Allbase is still in hot development and not production ready. We currently only ship a pre-release dev branch for contributors.
ark is still in hot development and not production ready. We currently only ship a pre-release dev branch for contributors.

`git clone https://github.com/TimothyStiles/allbase && cd allbase && go test -v ./...`
`git clone https://github.com/TimothyStiles/ark && cd ark && go test -v ./...`

## Community

* **[Discord](https://discord.gg/Hc8Ncwt):** Chat about Allbase and join us for game nights on our discord server!
* **[Discord](https://discord.gg/Hc8Ncwt):** Chat about ark and join us for game nights on our discord server!

## Contributing

Expand All @@ -33,9 +33,9 @@ Allbase is still in hot development and not production ready. We currently only
* [MIT](LICENSE)

* Copyright (c) 2022 Timothy Stiles, Keoni Gandall
<!-- We're building a modern solution to the biotech data access problem. Too many siloed databases using terrible dataformats that can't crossref eachother. Allbase is still in hot development but as it stands now the plan is to have a single service that can search and cross reference sequences and pathways from genbank, rhea, chembl, and uniprot. All sequences get hashes so they have a unique identifier. Allbase should in the end be able to spit out JSON for every sequence it has and every pathway it can make. Keoni should write down how somewhere but search is going to be dummy fast and easy to use through an API. -->
<!-- We're building a modern solution to the biotech data access problem. Too many siloed databases using terrible dataformats that can't crossref eachother. ark is still in hot development but as it stands now the plan is to have a single service that can search and cross reference sequences and pathways from genbank, rhea, chembl, and uniprot. All sequences get hashes so they have a unique identifier. ark should in the end be able to spit out JSON for every sequence it has and every pathway it can make. Keoni should write down how somewhere but search is going to be dummy fast and easy to use through an API. -->
<!-- ## Specification
When completed allbase will have:
When completed ark will have:
* [x] Functions that pull data from Genbank, Rhea, CHEMBL, and Uniprot.
* [ ] Cron jobs for daily updates from public DBs mentioned above.
Expand All @@ -49,7 +49,7 @@ When completed allbase will have:
* [ ] deploy on push to main
* [ ] continuous db updates
* [ ] Annotate given sequence string
* [ ] Improved data streaming. Currently allbase downloads THEN inserts.
* [ ] Improved data streaming. Currently ark downloads THEN inserts.
* [ ] REST API endpoints to:
* [ ] Query for metabolic pathways:
* [x] Breadth first search
Expand Down
2 changes: 1 addition & 1 deletion db/cmd/clean.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ var cleanCmd = &cobra.Command{
Short: "Clean up the project",
Long: "Clean up the project",
Run: func(cmd *cobra.Command, args []string) {
os.Remove("allbase.db")
os.Remove("ark.db")
},
}
9 changes: 4 additions & 5 deletions db/cmd/download.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
package cmd

import (
"github.com/TimothyStiles/allbase/pkg/download"
"github.com/spf13/cobra"
)

/******************************************************************************
Allbase needs an easy and reproducible way to grab all of the data it uses.
ark needs an easy and reproducible way to grab all of the data it uses.
Some people would try to download everything manually with wget or curl but
that's bonkers and I'm not maintaining that. Instead I've made a multi-threaded webscraper.
To be honest most of you reading this will probably just want to use the build
command which will download AND insert all of the data into allbase for you
command which will download AND insert all of the data into ark for you
without any intermediary files but I'm leaving this here for the time being until
the build command is implemented.
Expand All @@ -38,8 +37,8 @@ Tim
var downloadCmd = &cobra.Command{
Use: "download",
Short: "Download data for standard deploy build. Run at your own risk.",
Long: "Download literally downloads all the base data needed to build a standard allbase deployment the amount of data is dummy high to casually test on your personal machine. Run at your own risk.",
Long: "Download literally downloads all the base data needed to build a standard ark deployment the amount of data is dummy high to casually test on your personal machine. Run at your own risk.",
Run: func(cmd *cobra.Command, args []string) {
download.Allbase()
download.ark()
},
}
10 changes: 5 additions & 5 deletions db/cmd/local.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ package cmd

// func local() {
// // TODO: Check to see if the database already exists. Tells the user to run clean if they want a new install.
// if _, err := os.Stat("allbase.db"); !os.IsNotExist(err) {
// log.Fatal("Database already exists. Run 'allbase clean' to remove it.")
// if _, err := os.Stat("ark.db"); !os.IsNotExist(err) {
// log.Fatal("Database already exists. Run 'ark clean' to remove it.")
// }

// // Begin SQLite
// log.Println("Creating database...")
// db, err := sqlx.Open("sqlite3", "allbase.db")
// db, err := sqlx.Open("sqlite3", "ark.db")
// if err != nil {
// log.Fatalf("Failed to open sqlite in allbase.db: %s", err)
// log.Fatalf("Failed to open sqlite in ark.db: %s", err)
// }

// // Execute our schema in memory
Expand Down Expand Up @@ -100,5 +100,5 @@ package cmd
// log.Fatalf("Failed to insert RheaTsvInsert trembl on: %s", err)
// }

// log.Printf("Finished allbase")
// log.Printf("Finished ark")
// }
6 changes: 3 additions & 3 deletions db/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ var (
)

var rootCmd = &cobra.Command{
Use: "allbase",
Short: "allbase is dummy fast database for engineering organisms.",
Long: `allbase is a dummy fast database for engineering organisms. Cross reference genbank, uniprot, chembl, and rhea and get you some JSON.`,
Use: "ark",
Short: "ark is dummy fast database for engineering organisms.",
Long: `ark is a dummy fast database for engineering organisms. Cross reference genbank, uniprot, chembl, and rhea and get you some JSON.`,
}

func Execute() {
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/TimothyStiles/allbase
module github.com/TimothyStiles/ark

go 1.18

Expand Down
12 changes: 6 additions & 6 deletions pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"
"path/filepath"

"github.com/TimothyStiles/allbase/pkg/env"
"github.com/TimothyStiles/ark/pkg/env"
)

// Read reads the config file and returns the config.
Expand All @@ -32,7 +32,7 @@ func Write(fileName string, config Config) error {
return nil
}

// Config is the configuration for the allbase application.
// Config is the configuration for the ark application.
type Config struct {
// Production or development.
IsProd bool `json:"prod"`
Expand All @@ -43,8 +43,8 @@ type Config struct {
// DataPath is the data directory of the project.
DataPath string `json:"data_path"`

// AllbasePath is the path to the allbase sqlite database.
AllbasePath string `json:"allbase_path"`
// arkPath is the path to the ark sqlite database.
arkPath string `json:"ark_path"`

// RheaRDF is the path to the Rhea RDF file.
RheaRDF string `json:"rhea_rdf"`
Expand Down Expand Up @@ -80,7 +80,7 @@ func DevDefault() Config {
IsProd: false,
RootPath: env.RootPath(),
DataPath: devPath,
AllbasePath: filepath.Join(devPath, "allbase.sqlite"),
arkPath: filepath.Join(devPath, "ark.sqlite"),
RheaRDF: filepath.Join(devPath, "rhea_mini.rdf.gz"),
RheaToUniprotSprot: filepath.Join(devPath, "rhea_to_uniprot_sprot.tsv.gz"),
RheaToUniprotTrembl: filepath.Join(devPath, "rhea_to_uniprot_trembl.tsv.gz"),
Expand All @@ -101,7 +101,7 @@ func ProdDefault() Config {
IsProd: true,
RootPath: env.RootPath(),
DataPath: prodPath,
AllbasePath: filepath.Join(prodPath, "allbase.sqlite"),
arkPath: filepath.Join(prodPath, "ark.sqlite"),
RheaRDF: filepath.Join(prodPath, "rhea.rdf.gz"),
RheaToUniprotSprot: filepath.Join(prodPath, "rhea_to_uniprot_sprot.tsv"),
RheaToUniprotTrembl: filepath.Join(prodPath, "rhea_to_uniprot_trembl.tsv"),
Expand Down
4 changes: 2 additions & 2 deletions pkg/download/download.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package download

// Allbase literally downloads all the base data needed to build a standard allbase deployment
// ark literally downloads all the base data needed to build a standard ark deployment
// the amount of data is dummy high to casually test on your personal machine. Run at your own risk.
func Allbase() {
func ark() {
writePath := "../data/build"

// Typically I'd write these functions to return errors but since I'm using go routines
Expand Down
2 changes: 1 addition & 1 deletion pkg/download/file_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"
"testing"

"github.com/TimothyStiles/allbase/pkg/download"
"github.com/TimothyStiles/ark/pkg/download"
)

func TestFile(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion pkg/download/links_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package download_test
import (
"testing"

"github.com/TimothyStiles/allbase/pkg/download"
"github.com/TimothyStiles/ark/pkg/download"
)

func TestGetPageLinks(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion pkg/download/rhea.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package download

//Rhea downloads all required files for allbase from the Rhea database.
// Rhea downloads all required files for ark from the Rhea database.
func Rhea(writePath string) {
go File("https://ftp.expasy.org/databases/rhea/rdf/rhea.rdf.gz", writePath)

Expand Down
2 changes: 1 addition & 1 deletion pkg/download/tarball_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"os"
"testing"

"github.com/TimothyStiles/allbase/pkg/download"
"github.com/TimothyStiles/ark/pkg/download"
)

func TestTarball(t *testing.T) {
Expand Down
Loading

0 comments on commit 03e6f3b

Please sign in to comment.