Azzindani/Open_Reaction_Data huggingface dataset:
Reaction SMILES: [CH3:1][N:2]1[C:10]2([CH2:15][CH2:14][N:13]([C:16]([O:18][C:19]([CH3:22])([CH3:21])[CH3:20])=[O:17])[CH2:12][CH2:11]2)[C:6]2=[CH:7][CH:8]=[CH:9][N:5]2[CH2:4][CH2:3]1.[Br:23]N1C(=O)CCC1=O>C(Cl)Cl.[O-]S([O-])(=S)=O.[Na+].[Na+]>[Br:23][C:9]1[N:5]2[CH2:4][CH2:3][N:2]([CH3:1])[C:10]3([CH2:11][CH2:12][N:13]([C:16]([O:18][C:19]([CH3:22])([CH3:21])[CH3:20])=[O:17])[CH2:14][CH2:15]3)[C:6]2=[CH:7][CH:8]=1
Reactant: CN1CCn2cccc2C12CCN(C(=O)OC(C)(C)C)CC2
Reactant: O=C1CCC(=O)N1Br
Agent: O=S([O-])([O-])=S
Agent: [Na+]
Solvent: ClCCl
Product: CN1CCn2c(Br)ccc2C12CCN(C(=O)OC(C)(C)C)CC2
Temperature: 0 °C
Reaction time: 0.5 h

Procedure:
To tert-butyl 2-methylspiro[3,4-dihydropyrrolo[1,2-a]pyrazine-1,4′-piperidine]-1′-carboxylate (10 g, 32.74 mmol) in methylene chloride (73.5 mL) at 0° C. was added N-bromosuccinimide (5.53 g, 31.10 mmol) portionwise. The reaction was stirred at 0° C. After 30 minutes, additional N-bromosuccinimide (291.4 mg, 1.64 mmol) was added and the reaction was stirred for 1 hour. The reaction was diluted with 0.5 M Na2S2O3 (135 mL) and the aqueous phase was removed. The organic layer was washed with brine (135 mL). The organic layer was dried over sodium sulfate, filtered and the solvent was evaporated under reduced pressure to yield tert-butyl 6-bromo-2-methyl-spiro[3,4-dihydropyrrolo[1,2-a]pyrazine-1,4′-piperidine]-1′-carboxylate as a red viscous liquid that was used in the next step without further purification. 1H NMR (400 MHz, DMSO) δ 6.09 (d, J=3.7 Hz, 1H), 5.99 (d, J=3.7 Hz, 1H), 3.78-3.65 (m, 4H), 3.27 (t, J=6.0 Hz, 2H), 3.17-2.92 (m, 2H), 2.21 (s, 3H), 2.03-1.93 (m, 2H), 1.65-1.53 (m, 2H), 1.40 (s, 9H). ESI-MS m/z calc. 383.1, found 386.0 (M+1)+; Retention time: 1.13 minutes (3 minute run).
Reaction SMILES: II.Br[CH2:4][CH2:5][CH2:6][CH2:7][CH2:8][CH2:9][CH2:10][CH2:11][CH2:12][CH2:13][CH3:14].[CH2:15]([N:22]([C@@H:30]([CH3:33])[CH:31]=[O:32])[CH2:23][C:24]1[CH:29]=[CH:28][CH:27]=[CH:26][CH:25]=1)[C:16]1[CH:21]=[CH:20][CH:19]=[CH:18][CH:17]=1>C1COCC1>[CH2:23]([N:22]([C@H:30]([C@H:31]([OH:32])[CH2:14][CH2:13][CH2:12][CH2:11][CH2:10][CH2:9][CH2:8][CH2:7][CH2:6][CH2:5][CH3:4])[CH3:33])[CH2:15][C:16]1[CH:21]=[CH:20][CH:19]=[CH:18][CH:17]=1)[C:24]1[CH:29]=[CH:28][CH:27]=[CH:26][CH:25]=1
Reactant: C[C@@H](C=O)N(Cc1ccccc1)Cc1ccccc1
Reactant: CCCCCCCCCCCBr
Agent: II
Solvent: C1CCOC1
Product: CCCCCCCCCCC[C@@H](O)[C@H](C)N(Cc1ccccc1)Cc1ccccc1
Temperature: 60 °C
Yield: 44.7 %

Procedure:
To a suspension of Mg (155 mg, 6.38 mmol) and a few crystals of I2 in THF (3.1 mL), an aliquot of 1-bromoundecane (0.25 mL, 1.12 mmol) was added and the mixture was stirred at 60° C. until the red color of the solution disappeared. Then the remainder of 1-bromoundecane (0.46 mL, 2.07 mmol) was added and the reaction was stirred at room temperature for 1 h. The Grignard solution formed thereof was cooled down to 0° C. and a solution of aldehyde 4 (323.5 mg, 1.28 mmol) in THF (1.6 mL) was added via cannula. After stirring overnight at room temperature, the reaction was quenched with HCl (3N, 10 mL) extracted with EtOAc (3×10 mL), washed successively with NaHCO3 (20 mL, sat. aq.) and brine (20 mL), dried over Na2SO4 and concentrated in vacuo. The crude was purified by column chromatography on silica (100% hexane to 10:1 hexane/EtOAc) to obtain a mixture of diastereoisomers. Further purification by HPLC on silica (95:5 to 80:20 hexane/MTBE) afforded pure anti alcohol 29 as a colorless oil (205 mg, 39% yield).