forResearch method

AnthropicBuilder forResearch({
  1. required String experimentId,
  2. required String researcherId,
  3. String? hypothesis,
  4. Map<String, dynamic>? experimentParameters,
})

Configure for research with experiment tracking

Sets up metadata for research and experimentation with detailed tracking information.

Implementation

AnthropicBuilder forResearch({
  required String experimentId,
  required String researcherId,
  String? hypothesis,
  Map<String, dynamic>? experimentParameters,
}) {
  final metadata = <String, dynamic>{
    'environment': 'research',
    'experiment_id': experimentId,
    'researcher_id': researcherId,
    'timestamp': DateTime.now().toIso8601String(),
  };

  if (hypothesis != null) metadata['hypothesis'] = hypothesis;
  if (experimentParameters != null) {
    metadata['experiment_parameters'] = experimentParameters;
  }

  return this.metadata(metadata);
}