<commit_before>import {
  Input,
  Directive,
  EventEmitter,
  ElementRef,
  ViewContainerRef,
  TemplateRef,
} from '@angular/core';

import { ExperimentsService } from './experiments.service';

@Directive({
  selector: '[mExperiment]',
})
export class ExperimentDirective {
  @Input('mExperiment') mExperimentId;
  @Input() mExperimentBucket;

  constructor(
    private _service: ExperimentsService,
    private _viewContainer: ViewContainerRef,
    private _templateRef: TemplateRef<any>
  ) {}

  async ngOnInit() {
    if (this.mExperimentBucket === 'base')
      //load the base first
      this._viewContainer.createEmbeddedView(this._templateRef);

    if (
      await this._service.shouldRender({
        experimentId: this.mExperimentId,
        bucketId: this.mExperimentBucket,
      })
    ) {
      console.log('clearing');
      this._viewContainer.clear();
      this._viewContainer.createEmbeddedView(this._templateRef);
    } else {
      console.log('clearing');
      this._viewContainer.clear();
    }<commit_msg>(chore): remove console log for experiments<commit_after>import {
  Input,
  Directive,
  EventEmitter,
  ElementRef,
  ViewContainerRef,
  TemplateRef,
} from '@angular/core';

import { ExperimentsService } from './experiments.service';

@Directive({
  selector: '[mExperiment]',
})
export class ExperimentDirective {
  @Input('mExperiment') mExperimentId;
  @Input() mExperimentBucket;

  constructor(
    private _service: ExperimentsService,
    private _viewContainer: ViewContainerRef,
    private _templateRef: TemplateRef<any>
  ) {}

  async ngOnInit() {
    if (this.mExperimentBucket === 'base')
      //load the base first
      this._viewContainer.createEmbeddedView(this._templateRef);

    if (
      await this._service.shouldRender({
        experimentId: this.mExperimentId,
        bucketId: this.mExperimentBucket,
      })
    ) {
      this._viewContainer.clear();
      this._viewContainer.createEmbeddedView(this._templateRef);
    } else {
      this._viewContainer.clear();
    }
{'fraction_non_alphanumeric': 0.11508325171400588, 'fraction_numerical': 0.0, 'mean_word_length': 3.6221719457013575, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6075171', 'n_tokens_mistral': 612, 'n_tokens_neox': 600, 'n_words': 115}