malva.search module

malva.search.read_sequences_file(file_path)[source]

Read sequences from a file (supports FASTA format)

Uses dnaio for efficient and robust parsing of FASTA/FASTQ files.

Parameters:

file_path (str) – Path to the sequence file (FASTA or FASTQ)

Return type:

List[str]

Returns:

List of sequences without headers

malva.search.check_server_connection(server_url)[source]

Check if the Malva search server is running

Return type:

bool

malva.search.submit_search_job(server_url, query, dataset_id=None, include_metadata=False)[source]

Submit a search job to the server

Return type:

Dict[str, Any]

malva.search.get_datasets(server_url)[source]

Get list of available datasets from the server

Return type:

List[Dict[str, Any]]

malva.search.get_job_status(server_url, job_id)[source]

Get status of a job from the server

Return type:

Dict[str, Any]

malva.search.format_results(results, format_type='text')[source]

Format search results for output

Return type:

str

malva.search.wait_for_completion(server_url, job_id, poll_interval=1)[source]

Wait for a job to complete, showing progress

Return type:

Dict[str, Any]