Class: OpenReviewPlugin
Defined in: src/plugins/builtin/openreview.ts:258
OpenReview integration plugin.
Remarks
Fetches submissions from OpenReview via API v2 and imports them into the Chive AppView cache. Users can claim papers they authored using their verified OpenReview profile.
OpenReview profiles with linked ORCID/Semantic Scholar provide high-confidence verification for the multi-authority claiming system.
Extends ImportingPlugin for standardized import/claiming workflow.
Example
const plugin = new OpenReviewPlugin();
await manager.loadBuiltinPlugin(plugin);
// Verify author for claiming
const author = await plugin.getAuthorProfile('~Jane_Doe1');
if (author?.orcid) {
// High-confidence match for claiming
}
Extends
Implements
Constructors
new OpenReviewPlugin()
new OpenReviewPlugin():
OpenReviewPlugin
Returns
Inherited from
Properties
cache
protectedcache:ICacheProvider
Defined in: src/plugins/builtin/base-plugin.ts:88
Cache provider (available after initialization).
Inherited from
context
protectedcontext:IPluginContext
Defined in: src/plugins/builtin/base-plugin.ts:78
Plugin context (available after initialization).
Inherited from
id
readonlyid:"pub.chive.plugin.openreview"='pub.chive.plugin.openreview'
Defined in: src/plugins/builtin/openreview.ts:262
Plugin ID.
Implementation of
Overrides
importService
protectedimportService:IImportService
Defined in: src/plugins/core/importing-plugin.ts:83
Import service instance.
Remarks
Set during initialization via dependency injection from context.
Inherited from
logger
protectedlogger:ILogger
Defined in: src/plugins/builtin/base-plugin.ts:83
Logger instance (available after initialization).
Inherited from
manifest
readonlymanifest:IPluginManifest
Defined in: src/plugins/builtin/openreview.ts:277
Plugin manifest.
Implementation of
Overrides
metrics
protectedmetrics:IMetrics
Defined in: src/plugins/builtin/base-plugin.ts:93
Metrics provider (available after initialization).
Inherited from
rateLimitDelayMs
protectedrateLimitDelayMs:number=1000
Defined in: src/plugins/core/importing-plugin.ts:97
Minimum delay between requests in milliseconds.
Remarks
Override in subclass to set source-specific rate limit. Default: 1000ms (1 request per second)
Inherited from
ImportingPlugin.rateLimitDelayMs
source
readonlysource:"openreview"
Defined in: src/plugins/builtin/openreview.ts:267
Import source identifier.
Overrides
supportsSearch
readonlysupportsSearch:true
Defined in: src/plugins/builtin/openreview.ts:272
Indicates this plugin supports on-demand search.
Implementation of
SearchablePlugin.supportsSearch
Methods
buildPdfUrl()
buildPdfUrl(
externalId):null|string
Defined in: src/plugins/builtin/openreview.ts:422
Builds the PDF URL for an OpenReview submission.
Parameters
externalId
string
Note ID
Returns
null | string
PDF URL or null
Overrides
buildPreprintUrl()
buildPreprintUrl(
externalId):string
Defined in: src/plugins/builtin/openreview.ts:412
Builds the canonical URL for an OpenReview submission.
Parameters
externalId
string
Note ID
Returns
string
Full URL to the submission
Overrides
ImportingPlugin.buildPreprintUrl
fetchPreprints()
fetchPreprints(
options?):AsyncIterable<ExternalPreprint>
Defined in: src/plugins/builtin/openreview.ts:346
Fetches submissions from OpenReview.
Parameters
options?
Fetch options (limit, cursor, filters)
Returns
AsyncIterable<ExternalPreprint>
Async iterable of external preprints
Overrides
ImportingPlugin.fetchPreprints
fetchSubmissionDetails()
fetchSubmissionDetails(
noteId):Promise<null|OpenReviewPaper>
Defined in: src/plugins/builtin/openreview.ts:745
Fetches details for a specific submission.
Parameters
noteId
string
Submission note ID
Returns
Promise<null | OpenReviewPaper>
Paper details or null
findAuthorByEmail()
findAuthorByEmail(
Promise<null|OpenReviewAuthor>
Defined in: src/plugins/builtin/openreview.ts:597
Searches for author profile by email (for claiming verification).
Parameters
email
string
Email address to search
Returns
Promise<null | OpenReviewAuthor>
Author profile or null
getAuthorProfile()
getAuthorProfile(
profileId):Promise<null|OpenReviewAuthor>
Defined in: src/plugins/builtin/openreview.ts:504
Gets author profile for claiming verification.
Parameters
profileId
string
OpenReview profile ID (tilde ID like ~John_Doe1)
Returns
Promise<null | OpenReviewAuthor>
Author profile or null
Remarks
OpenReview profiles with linked ORCID provide high-confidence verification for the multi-authority claiming system.
getAuthorSubmissions()
getAuthorSubmissions(
profileId,options?):Promise<readonlyOpenReviewPaper[]>
Defined in: src/plugins/builtin/openreview.ts:640
Gets submissions authored by a profile ID.
Parameters
profileId
string
OpenReview profile ID
options?
Query options
limit
number
Returns
Promise<readonly OpenReviewPaper[]>
Papers authored by the profile
getConfig()
protectedgetConfig<T>(key):undefined|T
Defined in: src/plugins/builtin/base-plugin.ts:226
Gets a configuration value with type safety.
Type Parameters
• T
Parameters
key
string
Configuration key
Returns
undefined | T
Configuration value or undefined
Example
const apiKey = this.getConfig<string>('apiKey');
Inherited from
getExistingImport()
getExistingImport(
externalId):Promise<null|ImportedPreprint>
Defined in: src/plugins/core/importing-plugin.ts:167
Gets an existing import by external ID.
Parameters
externalId
string
Source-specific identifier
Returns
Promise<null | ImportedPreprint>
Imported preprint or null if not found
Inherited from
ImportingPlugin.getExistingImport
getPaper()
getPaper(
id):Promise<null|OpenReviewPaper>
Defined in: src/plugins/builtin/openreview.ts:733
Gets a cached paper by ID.
Parameters
id
string
Note ID
Returns
Promise<null | OpenReviewPaper>
Paper metadata or null
getRequiredConfig()
protectedgetRequiredConfig<T>(key):T
Defined in: src/plugins/builtin/base-plugin.ts:242
Gets a required configuration value.
Type Parameters
• T
Parameters
key
string
Configuration key
Returns
T
Configuration value
Throws
Error if key not found
Example
const apiKey = this.getRequiredConfig<string>('apiKey');
Inherited from
ImportingPlugin.getRequiredConfig
getState()
getState():
PluginState
Defined in: src/plugins/builtin/base-plugin.ts:162
Gets current plugin state.
Returns
Current lifecycle state
Implementation of
Inherited from
importPreprint()
importPreprint(
preprint):Promise<ImportedPreprint>
Defined in: src/plugins/core/importing-plugin.ts:185
Imports a preprint into the AppView cache.
Parameters
preprint
External preprint data
Returns
Promise<ImportedPreprint>
Created or existing imported preprint
Remarks
Performs deduplication and emits import.created event on success.
Throws
Error if import service unavailable
Inherited from
ImportingPlugin.importPreprint
initialize()
initialize(
context):Promise<void>
Defined in: src/plugins/core/importing-plugin.ts:107
Initializes the importing plugin.
Parameters
context
Plugin context with injected dependencies
Returns
Promise<void>
Remarks
Retrieves import service from context and calls onInitialize().
Implementation of
Inherited from
isImported()
isImported(
externalId):Promise<boolean>
Defined in: src/plugins/core/importing-plugin.ts:153
Checks if a preprint has already been imported.
Parameters
externalId
string
Source-specific identifier
Returns
Promise<boolean>
True if already imported
Inherited from
onInitialize()
protectedonInitialize():Promise<void>
Defined in: src/plugins/builtin/openreview.ts:328
Initializes the plugin.
Returns
Promise<void>
Remarks
Sets up rate limiting. No startup bulk import since this plugin uses on-demand search via the search() method.
Overrides
onShutdown()
protectedonShutdown():Promise<void>
Defined in: src/plugins/builtin/base-plugin.ts:211
Override in subclass for shutdown logic.
Returns
Promise<void>
Remarks
Called during shutdown(). Use this to:
- Save state
- Close connections
- Clean up resources
Default implementation does nothing.
Example
protected async onShutdown(): Promise<void> {
await this.saveState();
this.connection?.close();
}
Inherited from
parseExternalId()
parseExternalId(
url):null|string
Defined in: src/plugins/builtin/openreview.ts:432
Parses external ID from an OpenReview URL.
Parameters
url
string
OpenReview URL
Returns
null | string
Note ID or null
Overrides
ImportingPlugin.parseExternalId
rateLimit()
protectedrateLimit():Promise<void>
Defined in: src/plugins/core/importing-plugin.ts:342
Enforces rate limiting for external requests.
Returns
Promise<void>
Remarks
Call this before making external API/HTTP requests. Delays execution if needed to respect rate limit.
Inherited from
recordCounter()
protectedrecordCounter(name,labels?,value?):void
Defined in: src/plugins/builtin/base-plugin.ts:257
Records a counter metric.
Parameters
name
string
Metric name
labels?
Record<string, string>
Optional labels
value?
number
Optional increment value (default 1)
Returns
void
Inherited from
recordGauge()
protectedrecordGauge(name,value,labels?):void
Defined in: src/plugins/builtin/base-plugin.ts:268
Records a gauge metric.
Parameters
name
string
Metric name
value
number
Gauge value
labels?
Record<string, string>
Optional labels
Returns
void
Inherited from
runImportCycle()
runImportCycle(
options?):Promise<ImportCycleResult>
Defined in: src/plugins/core/importing-plugin.ts:285
Runs a full import cycle.
Parameters
options?
Fetch options
Returns
Promise<ImportCycleResult>
Import statistics
Remarks
Fetches preprints and imports new ones, updating existing ones. Respects rate limits and handles errors gracefully.
Inherited from
ImportingPlugin.runImportCycle
search()
search(
query):Promise<readonlyExternalPreprint[]>
Defined in: src/plugins/builtin/openreview.ts:819
Searches OpenReview for submissions matching the query.
Parameters
query
Search parameters (author, title, externalId)
Returns
Promise<readonly ExternalPreprint[]>
Matching submissions from OpenReview
Throws
If the search request fails
Remarks
Uses OpenReview API v2 for search queries. Supports searching by:
- Title text (content.title parameter)
- Author profile ID (content.authorids parameter)
- Note ID (exact match lookup)
Rate limiting: Enforces 600ms delay between requests.
Example
const results = await openReviewPlugin.search({
title: 'Attention Is All You Need',
limit: 10,
});
Implementation of
shutdown()
shutdown():
Promise<void>
Defined in: src/plugins/builtin/base-plugin.ts:142
Shuts down the plugin.
Returns
Promise<void>
Remarks
Calls onShutdown() and updates state. Subclasses should
override onShutdown() instead of this method.
Implementation of
Inherited from
startTimer()
protectedstartTimer(name,labels?): () =>void
Defined in: src/plugins/builtin/base-plugin.ts:286
Starts a timer for histogram metrics.
Parameters
name
string
Metric name
labels?
Record<string, string>
Optional labels
Returns
Function
Function to call when operation completes
Returns
void
Example
const endTimer = this.startTimer('api_request');
await this.fetchData();
endTimer(); // Records duration
Inherited from
updateImport()
updateImport(
id,preprint):Promise<ImportedPreprint>
Defined in: src/plugins/core/importing-plugin.ts:243
Updates an existing import with new data.
Parameters
id
number
Internal import ID
preprint
Partial<ExternalPreprint>
Updated preprint data
Returns
Promise<ImportedPreprint>
Updated imported preprint
Inherited from
verifyAuthorship()
verifyAuthorship(
profileId,submissionId):Promise<boolean>
Defined in: src/plugins/builtin/openreview.ts:696
Verifies if a profile ID is an author of a specific submission.
Parameters
profileId
string
OpenReview profile ID
submissionId
string
Submission note ID
Returns
Promise<boolean>
True if profile is an author