Skip to content

Commit

Permalink
Restructure Python v3 (Part 6) - Add Licensing Headers
Browse files Browse the repository at this point in the history
  • Loading branch information
dvonthenen committed Nov 10, 2023
1 parent bf15d79 commit 7159868
Show file tree
Hide file tree
Showing 22 changed files with 87 additions and 0 deletions.
4 changes: 4 additions & 0 deletions deepgram/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

# version
__version__ = '0.0.0'

Expand Down
4 changes: 4 additions & 0 deletions deepgram/client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

import re
from urllib.parse import urlparse, urlunparse, parse_qs, urlencode
from typing import Optional
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/abstract_client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

import httpx
import json
from typing import Dict, Any, Optional
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/listen.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from .prerecorded.client import PreRecordedClient
from .live.client import LiveClient
from typing import Dict, Any, Optional
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/live/client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from .enums import LiveTranscriptionEvents
from .helpers import convert_to_websocket_url, append_query_params

Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/live/enums.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from enum import Enum

class LiveTranscriptionEvents(Enum):
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/live/helpers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from urllib.parse import urlparse, urlunparse, parse_qs, urlencode

def append_query_params(url, params=""):
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/live/options.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from typing import Union, List, TypedDict

class LiveOptions(TypedDict, total=False):
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/manage/client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from .response import Project, ProjectsResponse, Message, ProjectOptions, KeysResponse, Key, KeyOptions, CreateKeyResponse, MembersResponse, ScopesResponse, ScopeOptions, InvitesResponse, InviteOptions, UsageRequestsResponse, UsageRequestOptions, UsageRequest, UsageSummaryOptions, UsageSummaryResponse, UsageFieldsResponse, UsageFieldsOptions, BalancesResponse, Balance

from ..abstract_client import AbstractRestfulClient
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/manage/response.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from datetime import datetime
from typing import TypedDict, List, Optional, Dict

Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/onprem/client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from ..abstract_client import AbstractRestfulClient

class OnPremClient(AbstractRestfulClient):
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/prerecorded/client.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from ...errors import DeepgramError
from ..abstract_client import AbstractRestfulClient

Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/prerecorded/helpers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from .source import PrerecordedSource

def is_buffer_source(provided_source: PrerecordedSource) -> bool:
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/prerecorded/options.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from typing import Union, List, TypedDict

class PrerecordedOptions(TypedDict, total=False):
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/prerecorded/response.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from typing import List, Optional, TypedDict, Dict

# Async Prerecorded Response Types:
Expand Down
4 changes: 4 additions & 0 deletions deepgram/clients/prerecorded/source.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from typing import Union
from io import BufferedReader
from typing_extensions import TypedDict
Expand Down
3 changes: 3 additions & 0 deletions deepgram/errors.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

class DeepgramError(Exception):
"""
Expand Down
4 changes: 4 additions & 0 deletions deepgram/options.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

class DeepgramClientOptions:

"""
Expand Down
4 changes: 4 additions & 0 deletions examples/demo_live.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

from dotenv import load_dotenv
import asyncio
import aiohttp
Expand Down
4 changes: 4 additions & 0 deletions examples/demo_manage.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

import asyncio
import os
from dotenv import load_dotenv
Expand Down
4 changes: 4 additions & 0 deletions examples/demo_prerecorded.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

import asyncio
import os
from dotenv import load_dotenv
Expand Down
4 changes: 4 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Copyright 2023 Deepgram SDK contributors. All Rights Reserved.
# Use of this source code is governed by a MIT license that can be found in the LICENSE file.
# SPDX-License-Identifier: MIT

import setuptools
import os.path

Expand Down

0 comments on commit 7159868

Please sign in to comment.