Skip to content

Commit a333b09

Browse files
committed
Initial commit
0 parents  commit a333b09

File tree

416 files changed

+84558
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

416 files changed

+84558
-0
lines changed

.app_env

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
REGISTRY=azimuth
2+
BACKEND_VERSION=latest
3+
FRONTEND_VERSION=latest
4+
DEVICE=cpu
5+
STAGE=production
6+
CFG_PATH=/config/examples/sst2/conf.json

.dockerignore

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
azimuth_shr/local_files
2+
azimuth_shr/files
3+
azimuth_shr/sentence_transformers
4+
azimuth_shr/tfhub
5+
cache
6+
dist
7+
.coverage*
8+
9+
# Must be kept in sync with webapp/.dockerignore
10+
webapp/node_modules
11+
webapp/build
12+
webapp/Makefile
13+
webapp/.npmrc

.flake8

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[flake8]
2+
max-line-length = 100
3+
ignore = W291,W503,E701,F401,F403,E203,E731
4+
exclude = azimuth_shr/sentence_transformers/

.gitattributes

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.ipynb linguist-detectable=false

.github/ISSUE_TEMPLATE/bug_report.md

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**To Reproduce**
14+
15+
Some advices:
16+
* Please don't use customer data or custom paths.
17+
* Link to a gist would be appreciated.
18+
19+
20+
**Expected behavior**
21+
A concise description of what you expected to happen.
22+
23+
24+
**Vesion (please complete the following information):**
25+
- OS:
26+
- Azimuth version:
27+
28+
**Additional context**
29+
Add any other context about the problem here.

.github/ISSUE_TEMPLATE/dev.md

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
name: Dev work
3+
about: New features
4+
title: ''
5+
assignees: ''
6+
labels: Dev
7+
project: 'Backend work'
8+
9+
---
10+
11+
**Is your feature request related to a problem? Please describe.**
12+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
13+
14+
**Describe the solution you'd like**
15+
A clear and concise description of what you want to happen.
16+
17+
**Describe alternatives you've considered**
18+
A clear and concise description of any alternative solutions or features you've considered.
19+
20+
**Additional context**
21+
Add any other context or screenshots about the feature request here.

.github/ISSUE_TEMPLATE/enhancement.md

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
---
2+
name: Enhancement
3+
about: Small changes
4+
title: ''
5+
assignees: ''
6+
labels: enhancement
7+
project: 'Backend work'
8+
9+
---
10+
11+
**Describe the solution you'd like**
12+
A clear and concise description of what you want to happen.
13+
14+
**Additional context**
15+
Add any other context or screenshots about the feature request here.

.github/ISSUE_TEMPLATE/frontend.md

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
name: User experience
3+
about: New features/experiments/research
4+
title: ''
5+
assignees: ''
6+
project: 'User features'
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe.**
11+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered.
18+
19+
**Additional context**
20+
Add any other context or screenshots about the feature request here.

.github/ISSUE_TEMPLATE/research.md

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
name: Research
3+
about: New research idea/project
4+
title: ''
5+
assignees: ''
6+
labels: research
7+
project: 'Backend work'
8+
9+
---
10+
11+
**What are the hypothesis?**
12+
**What is the new method?**
13+
**Is it risky?**
14+
**Is someone from Research helping us?**

.github/pull_request_template.md

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
## Summary:
2+
3+
### Features and fixes:
4+
5+
## Remember to:
6+
- Add unit tests for you code, if pertinent.
7+
- Add docstrings, typing and comments for complex sections.
8+
- Update the user documentation if this PR modifies the app and how users interact with it.
9+
- You updated the Github wiki if this PR modifies how we develop/launch on the app or contains any big design decisions.
10+
- If you played with types and routes, remember to regenerate the front-ent types, using `yarn
11+
types` while the back-end is running.
12+
13+
## Checklist:
14+
* [ ] You linked the issue number (Ex: Fixes #XXX). If no issue exists, you added the PR directly to a board.
15+
* [ ] You ran pre-commit on all commits, or else, you ran `pre-commit run --all-files` at the end.
16+
* [ ] The changes are added to CHANGELOG.md, if they impact our users. (You can check this to
17+
acknowledge that you thought about this.)

.github/workflows/pythonci.yml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Python package
2+
3+
on:
4+
push:
5+
branches: [ master, azimuth ]
6+
pull_request:
7+
branches: [ master, azimuth ]
8+
9+
jobs:
10+
build:
11+
12+
runs-on: ubuntu-latest
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
python-version: ["3.8"]
17+
18+
steps:
19+
- uses: actions/checkout@v2
20+
- name: Set up Python ${{ matrix.python-version }}
21+
uses: actions/setup-python@v2
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
- name: Install dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python -
28+
source $HOME/.poetry/env
29+
echo "$HOME/.poetry/bin" >> $GITHUB_PATH
30+
poetry config virtualenvs.create false && poetry install --no-interaction --no-ansi
31+
- name: Test with pytest/flake8/mypy
32+
run: |
33+
make test

.gitignore

+131
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
# Custom
2+
.circleci
3+
*.hdf5
4+
*.h5
5+
local_configs
6+
tmp
7+
cache
8+
*.lock
9+
!poetry.lock
10+
!yarn.lock
11+
12+
# Byte-compiled / optimized / DLL files
13+
__pycache__/
14+
*.py[cod]
15+
*$py.class
16+
17+
# C extensions
18+
*.so
19+
20+
# Distribution / packaging
21+
.Python
22+
build/
23+
develop-eggs/
24+
dist/
25+
downloads/
26+
eggs/
27+
.eggs/
28+
lib64/
29+
parts/
30+
sdist/
31+
var/
32+
wheels/
33+
*.egg-info/
34+
.installed.cfg
35+
*.egg
36+
MANIFEST
37+
38+
# PyInstaller
39+
# Usually these files are written by a python script from a template
40+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
41+
*.manifest
42+
*.spec
43+
44+
# Installer logs
45+
pip-log.txt
46+
pip-delete-this-directory.txt
47+
48+
# Unit test / coverage reports
49+
htmlcov/
50+
.tox/
51+
.coverage
52+
.coverage.*
53+
.cache
54+
nosetests.xml
55+
coverage.xml
56+
*.cover
57+
.hypothesis/
58+
.idea/
59+
.pytest_cache/
60+
61+
# Translations
62+
*.mo
63+
*.pot
64+
65+
# Django stuff:
66+
*.log
67+
local_settings.py
68+
db.sqlite3
69+
70+
# Flask stuff:
71+
instance/
72+
.webassets-cache
73+
74+
# Scrapy stuff:
75+
.scrapy
76+
77+
# Sphinx documentation
78+
docs/_build/
79+
80+
# mkdocs
81+
docs/site/
82+
83+
# PyBuilder
84+
target/
85+
86+
# Jupyter Notebook
87+
.ipynb_checkpoints
88+
89+
# pyenv
90+
.python-version
91+
92+
# celery beat schedule file
93+
celerybeat-schedule
94+
95+
# SageMath parsed files
96+
*.sage.py
97+
98+
# Environments
99+
.env
100+
.venv
101+
env/
102+
venv/
103+
ENV/
104+
env.bak/
105+
venv.bak/
106+
107+
# Spyder project settings
108+
.spyderproject
109+
.spyproject
110+
111+
# Rope project settings
112+
.ropeproject
113+
114+
# mkdocs documentation
115+
/site
116+
117+
# mypy
118+
.mypy_cache/
119+
120+
# VSCode
121+
.vscode/*
122+
123+
# macOS folder config
124+
.DS_Store
125+
dask-worker-space/
126+
127+
azimuth_shr/cached_models
128+
azimuth_shr/files
129+
azimuth_shr/local_files
130+
azimuth_shr/sentence_transformers
131+
azimuth_shr/tf_hub/

.pre-commit-config.yaml

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
repos:
2+
- repo: https://github.com/pre-commit/pre-commit-hooks
3+
rev: v2.3.0
4+
hooks:
5+
- id: check-yaml
6+
exclude: docs
7+
- id: end-of-file-fixer
8+
types: [ python ]
9+
- id: trailing-whitespace
10+
- id: pretty-format-json
11+
args: [--autofix, --no-sort-keys]
12+
exclude: webapp
13+
- repo: local
14+
hooks:
15+
- id: black
16+
name: black
17+
language: system
18+
entry: poetry run black
19+
minimum_pre_commit_version: 2.9.2
20+
require_serial: true
21+
types_or: [ python, pyi ]
22+
- repo: https://github.com/myint/autoflake
23+
rev: v1.4
24+
hooks:
25+
- id: autoflake
26+
args:
27+
- --expand-star-imports
28+
- --ignore-init-module-imports
29+
- --in-place
30+
- --remove-all-unused-imports
31+
- --remove-duplicate-keys
32+
- --remove-unused-variables
33+
- repo: local
34+
hooks:
35+
- id: prettier
36+
name: prettier
37+
language: system
38+
entry: bash -c 'cd webapp && poetry run yarn prettier --write .'
39+
files: webapp
40+
- repo: local
41+
hooks:
42+
- id: flake8
43+
name: flake8
44+
language: system
45+
entry: poetry run flake8
46+
types: [ python ]
47+
- repo: https://github.com/pycqa/isort
48+
rev: 5.8.0
49+
hooks:
50+
- id: isort
51+
name: isort
52+
args: [ "--profile", "black" ]
53+
- repo: local
54+
hooks:
55+
- id: mypy
56+
name: mypy
57+
language: system
58+
verbose: true
59+
entry: bash -c 'poetry run mypy "azimuth" || true' --
60+
files: azimuth
61+
pass_filenames: false

0 commit comments

Comments
 (0)