Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PTH005: Toolkit Modifications for API Endpoints Integration #126

Open
7 tasks done
tenzin3 opened this issue Jan 16, 2025 · 2 comments
Open
7 tasks done

PTH005: Toolkit Modifications for API Endpoints Integration #126

tenzin3 opened this issue Jan 16, 2025 · 2 comments
Assignees

Comments

@tenzin3
Copy link
Contributor

tenzin3 commented Jan 16, 2025

Description

We are developing endpoints to automate the conversion of our data into the OpenPecha Foundation (OPF) format and subsequently upload it to the pecha.org website. Therefore, modifications to the Toolkit are necessary to meet the requirements of these endpoints.

Expected Input from the API for parsing

  • input text in .docx format.
  • metadata as Dict.
  • type of text i.e Root/Translation

Expected Output

For this sprint, the endpoints will handle both the root text and the translation text, along with their metadata. The Toolkit should be capable of covert those to OPF and able to upload to pecha.org.

Implementation Steps

Fixes:

  • Avoid updating the Root OPF when publishing a translation OPF
  • take metadata input as a dictionary, not XLSX.
  • Return Pecha only from TranslationParser.
  • Make the serializer and parser static

To-Do:

  • Take translation's root info from catalog with metadata
  • Update the published pecha metadata to catalog.

Reviewer

@tenzin3 tenzin3 self-assigned this Jan 16, 2025
@tenzin3 tenzin3 converted this from a draft issue Jan 16, 2025
@tenzin3 tenzin3 changed the title PTH005: Toolkit Modifications for API end points PTH005: Toolkit Modifications for API Endpoints Integration Jan 16, 2025
@tenzin3
Copy link
Contributor Author

tenzin3 commented Jan 20, 2025

Modifications needed for Translation Parser

  • Take metadata as input
  • Return Pecha instance only
  • Rather than taking source_path as class constructor input, extract this info from the catalog.

@tenzin3 tenzin3 moved this from Triage to IN PROGRESS in Pecha for Tibet House Jan 22, 2025
@tenzin3
Copy link
Contributor Author

tenzin3 commented Jan 24, 2025

Fixes:
Modify Parser/ get root layer file name from Catalog
Modify Serializer/Get Root pecha id from Catalog and get content for translation Pecha

@ta4tsering ta4tsering moved this from IN PROGRESS to DONE in Pecha for Tibet House Jan 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: DONE
Development

No branches or pull requests

1 participant