server: use port 9931 by default (#30159)
* server: use port 9931 by default * revert unrelated changes
This commit is contained in:
1 parent
b013e56a71
commit
b42b7e6d30
40 files changed
+68
-66
No files matched your search
@@ -15,8 +15,8 @@ Unlike compare-logits.py, it allows dumping logits from a hosted API endpoint. U
|
||||
|
||||
Example usage:
|
||||
Step 1: Dump logits from two different servers
|
||||
python scripts/compare-logprobs.py dump logits_llama.log http://localhost:8080/v1/completions
|
||||
python scripts/compare-logprobs.py dump logits_other.log http://other-engine:8000/v1/completions
|
||||
python scripts/compare-logprobs.py dump logits_llama.log http://localhost:9931/v1/completions
|
||||
python scripts/compare-logprobs.py dump logits_other.log http://other-engine/v1/completions
|
||||
|
||||
(optionally, you can add --api-key <key> if the endpoint requires authentication)
|
||||
|
||||
|
||||
@@ -54,8 +54,8 @@ def get_server(path_server: str, path_log: Optional[str]) -> dict:
|
||||
logger.info("LLAMA_ARG_HOST not explicitly set, using 127.0.0.1")
|
||||
os.environ["LLAMA_ARG_HOST"] = "127.0.0.1"
|
||||
if os.environ.get("LLAMA_ARG_PORT") is None:
|
||||
logger.info("LLAMA_ARG_PORT not explicitly set, using 8080")
|
||||
os.environ["LLAMA_ARG_PORT"] = "8080"
|
||||
logger.info("LLAMA_ARG_PORT not explicitly set, using 9931")
|
||||
os.environ["LLAMA_ARG_PORT"] = "9931"
|
||||
hostname: Optional[str] = os.environ.get("LLAMA_ARG_HOST")
|
||||
port: Optional[str] = os.environ.get("LLAMA_ARG_PORT")
|
||||
assert hostname is not None
|
||||
|
||||
@@ -1096,7 +1096,7 @@ def main():
|
||||
description="Test llama-server tool-calling capability."
|
||||
)
|
||||
parser.add_argument("--host", default="localhost")
|
||||
parser.add_argument("--port", default=8080, type=int)
|
||||
parser.add_argument("--port", default=9931, type=int)
|
||||
parser.add_argument(
|
||||
"--no-stream", action="store_true", help="Disable streaming mode tests"
|
||||
)
|
||||
|
||||
@@ -183,7 +183,7 @@ def test_tool_call(url, stream):
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description="Test llama-server functionality.")
|
||||
parser.add_argument("--host", default="localhost", help="Server host")
|
||||
parser.add_argument("--port", default=8080, type=int, help="Server port")
|
||||
parser.add_argument("--port", default=9931, type=int, help="Server port")
|
||||
args = parser.parse_args()
|
||||
|
||||
base_url = f"http://{args.host}:{args.port}/v1/chat/completions"
|
||||
|
||||
@@ -938,7 +938,7 @@ def main():
|
||||
)
|
||||
)
|
||||
parser.add_argument("--host", default="localhost")
|
||||
parser.add_argument("--port", default=8080, type=int)
|
||||
parser.add_argument("--port", default=9931, type=int)
|
||||
parser.add_argument(
|
||||
"--no-stream", action="store_true", help="Disable streaming mode tests"
|
||||
)
|
||||
|
||||
@@ -991,7 +991,7 @@ def main():
|
||||
description="Test llama-server structured-output capability."
|
||||
)
|
||||
parser.add_argument("--host", default="localhost")
|
||||
parser.add_argument("--port", default=8080, type=int)
|
||||
parser.add_argument("--port", default=9931, type=int)
|
||||
parser.add_argument(
|
||||
"--no-stream", action="store_true", help="Disable streaming mode tests"
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user