Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
coderai
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexlab
coderai
Commits
5f86ba5b
Commit
5f86ba5b
authored
May 06, 2026
by
Stefy Lanza (nextime / spora )
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: scaffold manual multimodal test client
parent
2dd5754b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
81 additions
and
0 deletions
+81
-0
test_manual_multimodal_test_client.py
tests/test_manual_multimodal_test_client.py
+38
-0
manual_multimodal_test_client.py
tools/manual_multimodal_test_client.py
+43
-0
No files found.
tests/test_manual_multimodal_test_client.py
0 → 100644
View file @
5f86ba5b
from
pathlib
import
Path
from
types
import
SimpleNamespace
import
pytest
from
tools.manual_multimodal_test_client
import
build_parser
,
choose_mode_interactively
,
parse_args
def
test_parse_args_accepts_direct_mode_and_global_overrides
():
args
=
parse_args
([
"llm"
,
"--url"
,
"http://127.0.0.1:6745"
,
"--token"
,
"secret-token"
,
"--model"
,
"text:test-model"
,
"--prompt"
,
"Say hello"
,
"--output-dir"
,
"tmp/out"
,
])
assert
args
.
mode
==
"llm"
assert
args
.
url
==
"http://127.0.0.1:6745"
assert
args
.
token
==
"secret-token"
assert
args
.
model
==
"text:test-model"
assert
args
.
prompt
==
"Say hello"
assert
args
.
output_dir
==
"tmp/out"
def
test_choose_mode_interactively_maps_numeric_selection
(
monkeypatch
):
monkeypatch
.
setattr
(
"builtins.input"
,
lambda
_
:
"2"
)
mode
=
choose_mode_interactively
()
assert
mode
==
"transcription"
def
test_parse_args_leaves_mode_empty_for_interactive_fallback
():
args
=
parse_args
([])
assert
args
.
mode
is
None
tools/manual_multimodal_test_client.py
0 → 100644
View file @
5f86ba5b
from
__future__
import
annotations
import
argparse
from
pathlib
import
Path
from
typing
import
Optional
MODES
=
[
"llm"
,
"transcription"
,
"audio-generation"
,
"video-generation"
,
"video-doubt"
,
"music-audio-doubt"
,
]
def
build_parser
()
->
argparse
.
ArgumentParser
:
parser
=
argparse
.
ArgumentParser
(
description
=
"Manual multimodal smoke-test client"
)
parser
.
add_argument
(
"mode"
,
nargs
=
"?"
,
choices
=
MODES
)
parser
.
add_argument
(
"--url"
,
default
=
"http://127.0.0.1:6745"
)
parser
.
add_argument
(
"--token"
,
default
=
None
)
parser
.
add_argument
(
"--model"
,
default
=
None
)
parser
.
add_argument
(
"--prompt"
,
default
=
None
)
parser
.
add_argument
(
"--output-dir"
,
default
=
"tmp/manual-client-output"
)
parser
.
add_argument
(
"--file"
,
default
=
None
)
parser
.
add_argument
(
"--audio-file"
,
default
=
None
)
parser
.
add_argument
(
"--video-file"
,
default
=
None
)
return
parser
def
parse_args
(
argv
:
list
[
str
]
|
None
=
None
)
->
argparse
.
Namespace
:
return
build_parser
()
.
parse_args
(
argv
)
def
choose_mode_interactively
()
->
str
:
for
idx
,
mode
in
enumerate
(
MODES
,
start
=
1
):
print
(
f
"{idx}. {mode}"
)
raw
=
input
(
"Choose mode: "
)
.
strip
()
selected
=
int
(
raw
)
if
selected
<
1
or
selected
>
len
(
MODES
):
raise
ValueError
(
f
"Invalid mode selection: {raw}"
)
return
MODES
[
selected
-
1
]
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment