This directory contains shared vocabulary books that users can download and import into their WordMaster application.
index.json: The main registry file listing all available books.wordbook/: Directory containing the actual JSON data files for each vocabulary book.README.md: This documentation file.
To contribute a new vocabulary book to the Marketplace:
-
Create the Book Data File:
- Create a new JSON file in the
wordbook/directory (e.g.,wordbook/my_new_book.json). - Follow the JSON Schema below for the file content.
- Create a new JSON file in the
-
Update the Registry:
- Edit
index.json. - Add a new entry to the
bookarray pointing to your new file.
Example entry:
{ "name": "My New Book Name", "description": "A brief description of the vocabulary content.", "path": "wordbook/my_new_book.json" } - Edit
The wordbook JSON file should follow this structure:
{
"name": "Book Title",
"description": "Book Description",
"words": [
{
"word": "example",
"chinese": "n. 例子",
"phonetic": "/ɪɡˈzæmpəl/",
"part_of_speech": "noun",
"sentences": [
"This is a good example.",
"For example, you can do this."
]
}
]
}Each object in the words array represents a vocabulary item:
- word (string, required): The English word.
- chinese (string, required): The Chinese definition/translation.
- phonetic (string, optional): The IPA phonetic transcription.
- part_of_speech (string, optional): The grammatical category (e.g., "noun", "verb", "adj").
- sentences (array of strings, optional): Example sentences using the word.