Skip to content

Commit a5e5d9b

Browse files
john-walkoeclaude
andcommitted
Fix code formatting and add security infrastructure
Pre-commit hooks fixed trailing whitespace and end-of-file issues Security scanning infrastructure is now fully functional with: - GitHub Actions workflow for CI/CD scanning - Prompt injection detection - Secrets baseline tracking 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 21d59f7 commit a5e5d9b

38 files changed

+713
-728
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,4 +72,4 @@ uv.lock
7272
tests/archive/
7373

7474
# Claude assistant documents
75-
Claude_Documents/
75+
Claude_Documents/

.secrets.baseline

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,10 @@
9090
{
9191
"path": "detect_secrets.filters.allowlist.is_line_allowlisted"
9292
},
93+
{
94+
"path": "detect_secrets.filters.common.is_baseline_file",
95+
"filename": ".secrets.baseline"
96+
},
9397
{
9498
"path": "detect_secrets.filters.common.is_ignored_due_to_verification_policies",
9599
"min_level": 2
@@ -256,5 +260,5 @@
256260
}
257261
]
258262
},
259-
"generated_at": "2025-11-30T20:54:19Z"
263+
"generated_at": "2025-12-01T02:19:18Z"
260264
}

CUSTOMIZATION.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,4 +376,4 @@ uv run python tests/test_integration.py
376376
- `statuteBag` (may be empty for some petition types)
377377
- `petitionIssueConsideredTextBag` (depends on petition complexity)
378378

379-
This comprehensive field customization system allows you to optimize the MCP server for your specific petition analysis workflows while maintaining the flexibility to adjust as your needs evolve and new use cases emerge.
379+
This comprehensive field customization system allows you to optimize the MCP server for your specific petition analysis workflows while maintaining the flexibility to adjust as your needs evolve and new use cases emerge.

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1818
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1919
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2020
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21-
SOFTWARE.
21+
SOFTWARE.

PROMPTS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,4 +304,4 @@ All prompt templates include **Enhanced Input Processing** capabilities:
304304

305305
*For detailed usage examples and integration workflows, see [USAGE_EXAMPLES.md](USAGE_EXAMPLES.md).*
306306

307-
*For setup and installation guidance, see [README.md](README.md) and [INSTALL.md](INSTALL.md).*
307+
*For setup and installation guidance, see [README.md](README.md) and [INSTALL.md](INSTALL.md).*

deploy/manage_api_keys.ps1

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ except Exception as e:
112112
$usptoKey = ""
113113
$mistralKey = ""
114114
$error = ""
115-
115+
116116
foreach ($line in $lines) {
117117
if ($line.StartsWith("USPTO:")) {
118118
$usptoKey = $line.Substring(6)
@@ -122,12 +122,12 @@ except Exception as e:
122122
$error = $line.Substring(6)
123123
}
124124
}
125-
125+
126126
if ($error) {
127127
Write-Host "[ERROR] Failed to check API keys: $error" -ForegroundColor Red
128128
return $null
129129
}
130-
130+
131131
return @{
132132
"USPTO" = $usptoKey
133133
"Mistral" = $mistralKey
@@ -611,18 +611,18 @@ except Exception as e:
611611
# Function to show MCP-specific key requirements
612612
function Show-KeyRequirements {
613613
$mcpType = Get-McpType
614-
614+
615615
Write-Host ""
616616
Write-Host "API Key Requirements for $mcpType" -ForegroundColor Cyan
617617
Write-Host ("=" * (25 + $mcpType.Length)) -ForegroundColor Cyan
618-
618+
619619
switch -Wildcard ($mcpType) {
620620
"*FPD*" {
621621
Write-Host "USPTO API Key: [REQUIRED] For accessing Final Petition Decisions API" -ForegroundColor Green
622622
Write-Host "Mistral API Key: [OPTIONAL] For OCR on scanned documents" -ForegroundColor Yellow
623623
}
624624
"*PFW*" {
625-
Write-Host "USPTO API Key: [REQUIRED] For accessing Patent File Wrapper API" -ForegroundColor Green
625+
Write-Host "USPTO API Key: [REQUIRED] For accessing Patent File Wrapper API" -ForegroundColor Green
626626
Write-Host "Mistral API Key: [OPTIONAL] For OCR on scanned documents" -ForegroundColor Yellow
627627
}
628628
"*PTAB*" {
@@ -645,20 +645,20 @@ function Main {
645645
if (-not (Test-Requirements)) {
646646
exit 1
647647
}
648-
648+
649649
$mcpType = Get-McpType
650-
650+
651651
while ($true) {
652652
# Clear screen and show header
653653
Clear-Host
654654
Write-Host "USPTO MCP API Key Management" -ForegroundColor Cyan
655655
Write-Host "============================" -ForegroundColor Cyan
656656
Write-Host "MCP Type: $mcpType" -ForegroundColor Yellow
657657
Write-Host ""
658-
658+
659659
# Get current API key status
660660
$keys = Get-ApiKeyStatus
661-
661+
662662
if ($keys) {
663663
Write-Host "Current API Keys:" -ForegroundColor White
664664
$usptoDisplay = if ($keys.USPTO) { Hide-ApiKey -ApiKey $keys.USPTO } else { "[Not set]" }
@@ -668,7 +668,7 @@ function Main {
668668
} else {
669669
Write-Host "Unable to check current API key status" -ForegroundColor Red
670670
}
671-
671+
672672
Write-Host ""
673673
Write-Host "Actions:" -ForegroundColor White
674674
Write-Host " [1] Update USPTO API key"
@@ -681,7 +681,7 @@ function Main {
681681
Write-Host ""
682682

683683
$choice = Read-Host "Enter choice (1-7)"
684-
684+
685685
switch ($choice) {
686686
"1" {
687687
Write-Host ""
@@ -722,7 +722,7 @@ function Main {
722722
Write-Host ""
723723
Read-Host "Press Enter to continue"
724724
}
725-
725+
726726
"3" {
727727
Write-Host ""
728728
Write-Host "Remove API Key(s)" -ForegroundColor Cyan
@@ -732,9 +732,9 @@ function Main {
732732
Write-Host " [3] Remove ALL API keys"
733733
Write-Host " [4] Cancel"
734734
Write-Host ""
735-
735+
736736
$removeChoice = Read-Host "Enter choice (1-4)"
737-
737+
738738
switch ($removeChoice) {
739739
"1" { Remove-ApiKeys -USPTO }
740740
"2" { Remove-ApiKeys -Mistral }
@@ -749,11 +749,11 @@ function Main {
749749
"4" { Write-Host "[INFO] Operation cancelled" -ForegroundColor Yellow }
750750
default { Write-Host "[ERROR] Invalid choice" -ForegroundColor Red }
751751
}
752-
752+
753753
Write-Host ""
754754
Read-Host "Press Enter to continue"
755755
}
756-
756+
757757
"4" {
758758
Test-ApiKeys
759759
Write-Host ""
@@ -788,4 +788,4 @@ function Main {
788788
}
789789

790790
# Run the main function
791-
Main
791+
Main

reference/Document_Descriptions_List.csv

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -195,15 +195,15 @@ NEW
195195
FOLLOWON
196196
NEW
197197
FOLLOWON",,,,,,
198-
Amendment,Electronic Record Correction,"The USPTO has established a retention period of one year for patent-related papers
199-
that have been scanned into the Image File Wrapper system (IFW) or the
200-
Supplemental Complex Repository for Examiners (SCORE).
201-
After the expiration of the one-year retention period (after September 1, 2012, or later),
202-
the USPTO will dispose of the paper unless, within sufficient time
203-
prior to disposal of the paper, the relevant patent applicant, patent
204-
owner, or reexamination party files a bona fide request to correct the
205-
electronic record of the paper in IFW or SCORE, and the request remains
206-
outstanding at the time disposal of the paper would have otherwise
198+
Amendment,Electronic Record Correction,"The USPTO has established a retention period of one year for patent-related papers
199+
that have been scanned into the Image File Wrapper system (IFW) or the
200+
Supplemental Complex Repository for Examiners (SCORE).
201+
After the expiration of the one-year retention period (after September 1, 2012, or later),
202+
the USPTO will dispose of the paper unless, within sufficient time
203+
prior to disposal of the paper, the relevant patent applicant, patent
204+
owner, or reexamination party files a bona fide request to correct the
205+
electronic record of the paper in IFW or SCORE, and the request remains
206+
outstanding at the time disposal of the paper would have otherwise
207207
occurred. ",E.RECORD.COR,"
208208
DESIGN
209209
","
@@ -680,7 +680,7 @@ NEW
680680
FOLLOWON
681681
FOLLOWON
682682
NEW
683-
NEW
683+
NEW
684684
NEW
685685
FOLLOWON
686686
FOLLOWON",,,,,,
@@ -905,7 +905,7 @@ NEW
905905
NEW
906906
NEW
907907
FOLLOWON",,,,,,
908-
Application Part,Affidavit-Rule 131-pre-America Invents Act (First to Invent) ONLY,"When a reference applied by the Examiner has a patent or publication date less than 1 year before the U.S. filing date of the application being examined, applicant may file an affidavit or declaration under Rule 131(a) (Pre-AIA (FTI) Rule 131) to show prior inventorship to overcome the rejection.
908+
Application Part,Affidavit-Rule 131-pre-America Invents Act (First to Invent) ONLY,"When a reference applied by the Examiner has a patent or publication date less than 1 year before the U.S. filing date of the application being examined, applicant may file an affidavit or declaration under Rule 131(a) (Pre-AIA (FTI) Rule 131) to show prior inventorship to overcome the rejection.
909909
When any claim of an application or a patent under reexamination is rejected under 35 U.S.C. 103 on a U.S. patent or U.S. patent application publication which is not prior art under 35 U.S.C. 102(b), and the inventions defined by the claims in the application or patent under reexamination and by the claims in the patent or published application are not identical but are not patentably distinct, and the inventions are owned by the same party, the applicant or owner of the patent under reexamination may disqualify the patent or patent application publication as prior art by submission of an affidavit or declaration under Rule 131(c) (pre-AIA(FTI) Rule 130) stating common ownership and stating that the inventor named is the prior inventor.",AF/D.131 ,"371
910910
371
911911
AE_UTILITY
@@ -1106,15 +1106,15 @@ FOLLOWON",,,,,,
11061106
Change Requests - Supp Exam,Change of Address.,"Where an attorney or agent of record (or applicant, if he or she is prosecuting the application pro se) changes his or her correspondence address, he or she is responsible for promptly notifying the USPTO of the new correspondence address (including ZIP Code). The notification should also include his or her telephone number. A change of correspondence address must be signed by an attorney or agent of record.",C.AD ,SUPP EXAM (SE),"NEW
11071107
FOLLOWON
11081108
",,,,,,
1109-
Change Requests - Supp Exam,Electronic Record Correction,"The USPTO has established a retention period of one year for patent-related papers
1110-
that have been scanned into the Image File Wrapper system (IFW) or the
1111-
Supplemental Complex Repository for Examiners (SCORE).
1112-
After the expiration of the one-year retention period (after September 1, 2012, or later),
1113-
the USPTO will dispose of the paper unless, within sufficient time
1114-
prior to disposal of the paper, the relevant patent applicant, patent
1115-
owner, or reexamination party files a bona fide request to correct the
1116-
electronic record of the paper in IFW or SCORE, and the request remains
1117-
outstanding at the time disposal of the paper would have otherwise
1109+
Change Requests - Supp Exam,Electronic Record Correction,"The USPTO has established a retention period of one year for patent-related papers
1110+
that have been scanned into the Image File Wrapper system (IFW) or the
1111+
Supplemental Complex Repository for Examiners (SCORE).
1112+
After the expiration of the one-year retention period (after September 1, 2012, or later),
1113+
the USPTO will dispose of the paper unless, within sufficient time
1114+
prior to disposal of the paper, the relevant patent applicant, patent
1115+
owner, or reexamination party files a bona fide request to correct the
1116+
electronic record of the paper in IFW or SCORE, and the request remains
1117+
outstanding at the time disposal of the paper would have otherwise
11181118
occurred. ",E.RECORD.COR,SUPP EXAM (SE),"NEW
11191119
FOLLOWON
11201120
",,,,,,
@@ -2413,7 +2413,7 @@ REISSUE_UTILITY
24132413
TRACK 1","NEW
24142414
FOLLOWON
24152415
NEW
2416-
NEW
2416+
NEW
24172417
FOLLOWON
24182418
NEW
24192419
FOLLOWON
@@ -2425,15 +2425,15 @@ FOLLOWON
24252425
NEW
24262426
NEW",,,,,,
24272427
Petition,Petition auto-grant letter from EFS,A petition automatically granted in EFS-Web as long as the customer conforms to certain rules for the auto-grant,PET.DEC.AUTO,DESIGN,FOLLOWON,,,,,,
2428-
Petition,Electronic Record Correction,"The USPTO has established a retention period of one year for patent-related papers
2429-
that have been scanned into the Image File Wrapper system (IFW) or the
2430-
Supplemental Complex Repository for Examiners (SCORE).
2431-
After the expiration of the one-year retention period (after September 1, 2012, or later),
2432-
the USPTO will dispose of the paper unless, within sufficient time
2433-
prior to disposal of the paper, the relevant patent applicant, patent
2434-
owner, or reexamination party files a bona fide request to correct the
2435-
electronic record of the paper in IFW or SCORE, and the request remains
2436-
outstanding at the time disposal of the paper would have otherwise
2428+
Petition,Electronic Record Correction,"The USPTO has established a retention period of one year for patent-related papers
2429+
that have been scanned into the Image File Wrapper system (IFW) or the
2430+
Supplemental Complex Repository for Examiners (SCORE).
2431+
After the expiration of the one-year retention period (after September 1, 2012, or later),
2432+
the USPTO will dispose of the paper unless, within sufficient time
2433+
prior to disposal of the paper, the relevant patent applicant, patent
2434+
owner, or reexamination party files a bona fide request to correct the
2435+
electronic record of the paper in IFW or SCORE, and the request remains
2436+
outstanding at the time disposal of the paper would have otherwise
24372437
occurred. ",E.RECORD.COR,"371
24382438
DESIGN
24392439
PROVSNL
@@ -2640,8 +2640,8 @@ FOLLOWON",,,,,,
26402640
Pilot Programs,Request for Peer Review,The patent owner/assignee/applicant presents the form according to the provisions of the Peer to patent pilot to allow the application to be apart of the program.,PEER.CONSENT,"371
26412641
UTILITY","FOLLOWON
26422642
FOLLOWON",,,,,,
2643-
Pilot Programs,"
2644-
COVID-19 Prioritized Examination Request","
2643+
Pilot Programs,"
2644+
COVID-19 Prioritized Examination Request","
26452645
Allows an applicant that qualifies for small or micro entity status to file a request for prioritized examination in certain applications with a certification that the claimed invention covers a product or process related to COVID-19 and that the product or process is subject to an approval by the FDA.",TRACK1.COVID,"TRACK1
26462646
371
26472647
UTILITY","NEW
@@ -3044,8 +3044,8 @@ Supplemental Examination,Receipt of Original Supplemental Examination Request,"A
30443044
SUPP EXAM (SE)","NEW
30453045
FOLLOWON
30463046
",,,,,,
3047-
Track I - Prioritized Examination,"
3048-
COVID-19 Prioritized Examination Request","
3047+
Track I - Prioritized Examination,"
3048+
COVID-19 Prioritized Examination Request","
30493049
Allows an applicant that qualifies for small or micro entity status to file a request for prioritized examination in certain applications with a certification that the claimed invention covers a product or process related to COVID-19 and that the product or process is subject to an approval by the FDA.",TRACK1.COVID,"TRACK1
30503050
371
30513051
UTILITY","NEW

reference/FinalPetitionDecisions_swagger.yaml

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,7 @@ paths:
455455
application/json:
456456
schema:
457457
$ref: './odp-common-base.yaml#/components/schemas/Response500'
458-
458+
459459
/api/v1/petition/decisions/{petitionDecisionRecordIdentifier}:
460460
x-ip-domain: Patent
461461
x-service-type: ["Search","Dissemination"]
@@ -478,7 +478,7 @@ paths:
478478
description: Petition decision number
479479
- name: includeDocuments
480480
in: query
481-
description: This is a true or false...yes to include petition decision documents in the response and no to omit the petition decision documents from the response
481+
description: This is a true or false...yes to include petition decision documents in the response and no to omit the petition decision documents from the response
482482
schema:
483483
type: boolean
484484
example: true
@@ -514,7 +514,7 @@ paths:
514514
application/json:
515515
schema:
516516
$ref: './odp-common-base.yaml#/components/schemas/Response500'
517-
517+
518518
components:
519519

520520
securitySchemes:
@@ -532,21 +532,21 @@ components:
532532
$ref: ./odp-common-base.yaml#/components/schemas/PatentSearchRequest
533533
PatentDownloadRequest:
534534
$ref: ./odp-common-base.yaml#/components/schemas/PatentDownloadRequest
535-
PatentDataResponse:
535+
PatentDataResponse:
536536
$ref: ./odp-common-base.yaml#/components/schemas/PatentDataResponse
537-
ApplicationMetaData:
537+
ApplicationMetaData:
538538
$ref: ./odp-common-base.yaml#/components/schemas/ApplicationMetaData
539-
PatentTermAdjustment:
539+
PatentTermAdjustment:
540540
$ref: ./odp-common-base.yaml#/components/schemas/PatentTermAdjustment
541541
Assignment:
542542
$ref: ./odp-common-base.yaml#/components/schemas/Assignment
543-
RecordAttorney:
543+
RecordAttorney:
544544
$ref: ./odp-common-base.yaml#/components/schemas/RecordAttorney
545-
ParentContinuityData:
545+
ParentContinuityData:
546546
$ref: ./odp-common-base.yaml#/components/schemas/ParentContinuityData
547-
ChildContinuityData:
547+
ChildContinuityData:
548548
$ref: ./odp-common-base.yaml#/components/schemas/ChildContinuityData
549-
ForeignPriority:
549+
ForeignPriority:
550550
$ref: ./odp-common-base.yaml#/components/schemas/ForeignPriority
551551
EventData:
552552
$ref: ./odp-common-base.yaml#/components/schemas/EventData
@@ -557,7 +557,7 @@ components:
557557
GrantFileMetaData:
558558
$ref: ./odp-common-base.yaml#/components/schemas/GrantFileMetaData
559559
StatusCodeSearchResponse:
560-
$ref: ./odp-common-base.yaml#/components/schemas/StatusCodeSearchResponse
560+
$ref: ./odp-common-base.yaml#/components/schemas/StatusCodeSearchResponse
561561
# BulkData
562562
BdssResponseProductBag:
563563
$ref: ./odp-common-base.yaml#/components/schemas/BdssResponseProductBag
@@ -567,7 +567,7 @@ components:
567567
$ref: ./odp-common-base.yaml#/components/schemas/PetitionDecisionResponseBag
568568
PetitionDecisionIdentifierResponseBag:
569569
$ref: ./odp-common-base.yaml#/components/schemas/PetitionDecisionIdentifierResponseBag
570-
570+
571571
# Trial – Proceedings
572572
ProceedingDataResponse:
573573
$ref: ./trial-proceedings.yaml#/components/schemas/ProceedingDataResponse
@@ -632,5 +632,3 @@ components:
632632
$ref: ./trial-common.yaml#/components/schemas/Status413
633633
InternalError:
634634
$ref: ./trial-common.yaml#/components/schemas/InternalError
635-
636-

reference/petition-decision-schema.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,4 +172,4 @@
172172
"requestIdentifier",
173173
"petitionDecisionDataBag"
174174
]
175-
}
175+
}

0 commit comments

Comments
 (0)