Skip to content

Commit

Permalink
refactor: remove audio
Browse files Browse the repository at this point in the history
  • Loading branch information
vansangpfiev committed May 7, 2024
1 parent 95ec19a commit c01a6df
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 1,359 deletions.
3 changes: 0 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +0,0 @@
[submodule "cortex-cpp/whisper.cpp"]
path = cortex-cpp/whisper.cpp
url = https://github.com/ggerganov/whisper.cpp.git
6 changes: 2 additions & 4 deletions cortex-cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ endif()

add_compile_definitions(NITRO_VERSION="${NITRO_VERSION}")

add_subdirectory(whisper.cpp)
add_subdirectory(test)

add_executable(${PROJECT_NAME} main.cc)
Expand All @@ -69,7 +68,7 @@ add_executable(${PROJECT_NAME} main.cc)
# and comment out the following lines

find_package(Drogon CONFIG REQUIRED)
target_link_libraries(${PROJECT_NAME} PRIVATE Drogon::Drogon whisper
target_link_libraries(${PROJECT_NAME} PRIVATE Drogon::Drogon
${CMAKE_THREAD_LIBS_INIT})

# ##############################################################################
Expand All @@ -87,7 +86,6 @@ endif()

aux_source_directory(controllers CTL_SRC)
aux_source_directory(common COMMON_SRC)
aux_source_directory(context CONTEXT_SRC)
aux_source_directory(models MODEL_SRC)
aux_source_directory(cortex-common CORTEX_COMMON)
# aux_source_directory(filters FILTER_SRC) aux_source_directory(plugins
Expand All @@ -100,7 +98,7 @@ aux_source_directory(cortex-common CORTEX_COMMON)

target_include_directories(${PROJECT_NAME} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} )
# ${CMAKE_CURRENT_SOURCE_DIR}/models)
target_sources(${PROJECT_NAME} PRIVATE ${CTL_SRC} ${COMMON_SRC} ${CONTEXT_SRC})
target_sources(${PROJECT_NAME} PRIVATE ${CTL_SRC} ${COMMON_SRC})
# ${FILTER_SRC} ${PLUGIN_SRC} ${MODEL_SRC})
# ##############################################################################
# uncomment the following line for dynamically loading views set_property(TARGET
Expand Down
Empty file removed cortex-cpp/common/base.cc
Empty file.
16 changes: 0 additions & 16 deletions cortex-cpp/common/base.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,21 +37,5 @@ class BaseEmbedding {
const HttpRequestPtr& req,
std::function<void(const HttpResponsePtr&)>&& callback) = 0;

// The derived class can also override other methods if needed
};

class BaseAudio {
public:
virtual ~BaseAudio() {}
// Transcribes audio into the input language.
virtual void CreateTranscription(
const HttpRequestPtr& req,
std::function<void(const HttpResponsePtr&)>&& callback) = 0;

// Translates audio into the input language.
virtual void CreateTranslation(
const HttpRequestPtr& req,
std::function<void(const HttpResponsePtr&)>&& callback) = 0;

// The derived class can also override other methods if needed
};
Loading

0 comments on commit c01a6df

Please sign in to comment.