Skip to content

Creating or Editing a Search Profile

Evan Putnam edited this page May 29, 2024 · 4 revisions

Search Profiles in PMET

Search profiles can be adjusted to search by or acquire new criteria specific to your needs. Several resources and explanations of properties are listed in this document which can help in understanding how to use the Search Profile feature.

Note: the pmet-data.json file must follow JSON file structure or will be unreadable by the program and it will load the default settings or may error when starting.

Creating a New Search Profile

1. Open the PMET data file

The file can be located in your account's user folder, if the file is not in your account's user folder you will need to start the PMET program in order to generate the folder and its files.

The file is a generic text file so it can be opened in Notepad or any preferred text editor.

2. Find the profiles section

Scroll down to 'query_profiles'.

3. Copy this empty profile

{
                "profile_name": "empty",
                "query_type": "ti",
                "trim_terms": [
                    "DOCS.",
                    "DOCS",
                    "DOC"
                ],
                "removeWhiteSpace": false,
                "removePunctuation": false,
                "key_map": [
                    {
                        "name": "SuDoc",
                        "path": [
                            "classification",
                            "govDoc",
                            "0"
                        ]
                    },
                    {
                        "name": "Title",
                        "path": [
                            "title",
                            "mainTitles",
                            "0",
                            "text"
                        ]
                    }
                ]
            },

4. Insert it into the PMET data file

Paste the text into the file, if it is at the end you may need to remove the trailing comma to meet JSON file specifications.

5. Edit properties to meet your needs

Skip to here to learn about editing the query profile properties.

Editing a Search Profile

1. Open the PMET data file

The file can be located in your account's user folder, if the file is not in your account's user folder you will need to start the PMET program in order to generate the folder and its files.

The file is a generic text file so it can be opened in Notepad or any preferred text editor.

2. Find the profiles section

Scroll down to 'query_profiles'.

3. Edit Profile Properties

Edit the profile properties to meet your requirements, just be sure to follow standard JSON specification or errors may occur.

Profile Properties

  • profile_name - The name that appears in the program when selecting a profile and is also used to name the column in the resulting CSV.

  • query_type - This is the search type used for the query, the possible values are defined by OCLC and you can find more information about it (here)[https://help.oclc.org/Librarian_Toolbox/Searching_WorldCat_Indexes/Bibliographic_records/Bibliographic_record_indexes/Bibliographic_record_index_lists].

  • trim_terms - A list of terms which will be trimmed from the front of the query term. (With the default SuDoc profile a query term like 'DOCS PR 36.8' will be trimmed to 'PR 36.8')

  • removeWhiteSpace - Can be either true or false. When true it will remove all whitespace from the query term, including spaces, tabs, returns, newlines, and more common whitespace variants.

  • removePunctuation - Can be either true or false. When true it will remove all punctuation characters, leaving only letters and numbers.

  • key_map - A list of maps to values within the query results.

Clone this wiki locally