csv implementation

This commit is contained in:
2025-11-08 17:09:33 -08:00
parent 3ca921ad02
commit f2dc0d8a7b
3 changed files with 8 additions and 2 deletions

View File

@@ -1,7 +1,9 @@
[project] [project]
name = "ucsinfer" name = "ucsinfer"
version = "0.1.0" version = "0.1.0"
description = "Tools for applying UCS categories to sounds using large-language models" description = """
Tools for applying UCS categories to sounds using large-language models
"""
authors = [ authors = [
{name = "Jamie Hardt", email = "jamiehardt@me.com"} {name = "Jamie Hardt", email = "jamiehardt@me.com"}
] ]

3
ucsinfer/finetune.py Normal file
View File

@@ -0,0 +1,3 @@
from sentence_transformers import SentenceTransformerTrainingArguments
args = SentenceTransformerTrainingArguments(output_dir="finetuned/")

View File

@@ -5,7 +5,8 @@ from typing import Generator
from .util import parse_ucs from .util import parse_ucs
def csv_to_data(paths, description_key, filename_key, catid_list) -> Generator[tuple[str, str], None, None]: def csv_to_data(paths, description_key, filename_key, catid_list) \
-> Generator[tuple[str, str], None, None]:
""" """
Accepts a list of paths and returns an iterator of (sentence, class) Accepts a list of paths and returns an iterator of (sentence, class)
tuples. tuples.