-
Notifications
You must be signed in to change notification settings - Fork 435
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #98 from daily-co/use-pip-features
use pip optional dependencies
- Loading branch information
Showing
31 changed files
with
993 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: build | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- "**" | ||
paths-ignore: | ||
- "docs/**" | ||
|
||
concurrency: | ||
group: build-${{ github.event.pull_request.number || github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build: | ||
name: "Build and Install" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python | ||
id: setup_python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
- name: Setup virtual environment | ||
run: | | ||
python -m venv .venv | ||
- name: Install basic Python dependencies | ||
run: | | ||
source .venv/bin/activate | ||
python -m pip install --upgrade pip | ||
pip install -r dev-requirements.txt | ||
- name: Build project | ||
run: | | ||
source .venv/bin/activate | ||
python -m build | ||
- name: Install project and other Python dependencies | ||
run: | | ||
source .venv/bin/activate | ||
pip install --editable . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: publish | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
gitref: | ||
type: string | ||
description: "what git ref to build" | ||
required: true | ||
|
||
jobs: | ||
build: | ||
name: "Build and upload wheels" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.gitref }} | ||
- name: Set up Python | ||
id: setup_python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
- name: Cache virtual environment | ||
uses: actions/cache@v3 | ||
with: | ||
# We are hashing requirements-dev.txt and requirements-extra.txt which | ||
# contain all dependencies needed to run the tests and examples. | ||
key: venv-${{ runner.os }}-${{ steps.setup_python.outputs.python-version}}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements-dev.txt') }} | ||
path: .venv | ||
- name: Install system packages | ||
run: sudo apt-get install -y portaudio19-dev | ||
- name: Setup virtual environment | ||
run: | | ||
python -m venv .venv | ||
- name: Install basic Python dependencies | ||
run: | | ||
source .venv/bin/activate | ||
python -m pip install --upgrade pip | ||
pip install -r linux-py3.10-requirements.txt -r dev-requirements.txt | ||
- name: Build project | ||
run: | | ||
source .venv/bin/activate | ||
python -m build | ||
- name: Upload wheels | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
path: ./dist | ||
|
||
publish-to-pypi: | ||
name: "Publish to PyPI" | ||
runs-on: ubuntu-latest | ||
needs: [ build ] | ||
environment: | ||
name: pypi | ||
url: https://pypi.org/p/dailyai | ||
permissions: | ||
id-token: write | ||
steps: | ||
- name: Download wheels | ||
uses: actions/download-artifact@v4 | ||
with: | ||
path: ./dist | ||
- name: Publish to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
verbose: true | ||
print-hash: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
name: publish-test | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
name: "Build and upload wheels" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.gitref }} | ||
- name: Set up Python | ||
id: setup_python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
- name: Setup virtual environment | ||
run: | | ||
python -m venv .venv | ||
- name: Install basic Python dependencies | ||
run: | | ||
source .venv/bin/activate | ||
python -m pip install --upgrade pip | ||
pip install -r dev-requirements.txt | ||
- name: Build project | ||
run: | | ||
source .venv/bin/activate | ||
python -m build | ||
- name: Upload wheels | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
path: ./dist | ||
|
||
publish-to-pypi: | ||
name: "Test publish to PyPI" | ||
runs-on: ubuntu-latest | ||
needs: [ build ] | ||
environment: | ||
name: pypi | ||
url: https://pypi.org/p/dailyai | ||
permissions: | ||
id-token: write | ||
steps: | ||
- name: Download wheels | ||
uses: actions/download-artifact@v4 | ||
with: | ||
path: ./dist | ||
- name: Publish to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
verbose: true | ||
print-hash: true | ||
repository-url: https://test.pypi.org/legacy/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
autopep8==2.0.4 | ||
build==1.0.3 | ||
pip-tools==7.4.1 | ||
pytest==8.1.1 | ||
setuptools==69.2.0 | ||
setuptools_scm==8.0.4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,25 @@ | ||
OPENAI_API_KEY=... | ||
ELEVENLABS_API_KEY=... | ||
ELEVENLABS_VOICE_ID=... | ||
# Anthropic | ||
ANTHROPIC_API_KEY=... | ||
|
||
# Azure | ||
SPEECH_KEY=... | ||
SPEECH_REGION=... | ||
|
||
# Daily | ||
DAILY_API_KEY=... | ||
DAILY_SAMPLE_ROOM_URL=https://... | ||
|
||
# ElevenLabs | ||
ELEVENLABS_API_KEY=... | ||
ELEVENLABS_VOICE_ID=... | ||
|
||
# Fal | ||
FAL_KEY_ID=... | ||
FAL_KEY_SECRET=... | ||
|
||
# PlayHT | ||
PLAY_HT_USER_ID=... | ||
PLAY_HT_API_KEY=... | ||
|
||
# OpenAI | ||
OPENAI_API_KEY=... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.