adding python-dotenv
This commit is contained in:
parent
9493912034
commit
a3537f4a4d
|
@ -1,3 +1,6 @@
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
import threading
|
import threading
|
||||||
import os
|
import os
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import glob
|
import glob
|
||||||
import json
|
import json
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
|
@ -2,6 +2,10 @@
|
||||||
Exposes a SSE streaming server endpoint at /run, which recieves language and code,
|
Exposes a SSE streaming server endpoint at /run, which recieves language and code,
|
||||||
and streams the output.
|
and streams the output.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import json
|
import json
|
||||||
from interpreter import interpreter
|
from interpreter import interpreter
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
from starlette.websockets import WebSocketDisconnect
|
from starlette.websockets import WebSocketDisconnect
|
||||||
import ast
|
import ast
|
||||||
import json
|
import json
|
||||||
|
|
|
@ -2,6 +2,9 @@
|
||||||
Defines a function which takes a path to an audio file and turns it into text.
|
Defines a function which takes a path to an audio file and turns it into text.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
import os
|
import os
|
||||||
import contextlib
|
import contextlib
|
||||||
|
|
|
@ -2,6 +2,9 @@
|
||||||
Defines a function which takes text and returns a path to an audio file.
|
Defines a function which takes text and returns a path to an audio file.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import tempfile
|
import tempfile
|
||||||
from openai import OpenAI
|
from openai import OpenAI
|
||||||
from pydub import AudioSegment
|
from pydub import AudioSegment
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
import subprocess
|
import subprocess
|
||||||
import platform
|
import platform
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
load_dotenv() # take environment variables from .env.
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue